當前位置: 首頁>>代碼示例>>Java>>正文


Java JSplitPane.setLeftComponent方法代碼示例

本文整理匯總了Java中javax.swing.JSplitPane.setLeftComponent方法的典型用法代碼示例。如果您正苦於以下問題:Java JSplitPane.setLeftComponent方法的具體用法?Java JSplitPane.setLeftComponent怎麽用?Java JSplitPane.setLeftComponent使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在javax.swing.JSplitPane的用法示例。


在下文中一共展示了JSplitPane.setLeftComponent方法的15個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Java代碼示例。

示例1: initGui

import javax.swing.JSplitPane; //導入方法依賴的package包/類
protected TreeView initGui () {
    TTW retVal = new TTW () ;
    
    
    split = new JSplitPane (JSplitPane.HORIZONTAL_SPLIT);
    PropertySheetView propertyView = new PropertySheetView();
    
    split.setLeftComponent(retVal);
    split.setRightComponent(propertyView);
    // install proper border for split pane
    split.setBorder((Border)UIManager.get("Nb.ScrollPane.border")); // NOI18N

    setLayout (new java.awt.GridBagLayout ());

    GridBagConstraints gridBagConstraints = new GridBagConstraints ();
    gridBagConstraints.fill = GridBagConstraints.BOTH;
    gridBagConstraints.weightx = 1.0;
    gridBagConstraints.weighty = 1.0;
    gridBagConstraints.gridwidth = 2;
    add (split, gridBagConstraints);

    return retVal;
}
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:24,代碼來源:OptionsAction.java

示例2: initComponents

import javax.swing.JSplitPane; //導入方法依賴的package包/類
private void initComponents() {
	this.setLayout(new BorderLayout());
	//building mainPanel
	mainPanel = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT);
	mainPanel.setDividerSize(4);
	mainPanel.setBorder(new EmptyBorder(5, 5, 5, 5));
	//layout of main panel
	WarningScrollTable jsp = new WarningScrollTable(joinStrategies, WARNING_CLASS);
	jsp.setBorder(new TitledBorder(new EtchedBorder(), "Join Strategies"));
	mainPanel.setResizeWeight(1.0);
	jsp.setMinimumSize(new Dimension(200, 100));
	mainPanel.setLeftComponent(jsp);
	joinEditor.setMinimumSize(new Dimension(225, 100));
	mainPanel.setRightComponent(joinEditor);
	add(mainPanel, BorderLayout.CENTER);
}
 
開發者ID:max6cn,項目名稱:jmt,代碼行數:17,代碼來源:JoinSectionPanel.java

示例3: initComponents

import javax.swing.JSplitPane; //導入方法依賴的package包/類
private void initComponents() {
	this.setLayout(new BorderLayout());
	//building mainPanel
	mainPanel = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT);
	mainPanel.setDividerSize(4);
	mainPanel.setBorder(new EmptyBorder(5, 5, 5, 5));
	//layout of main panel
	WarningScrollTable jsp = new WarningScrollTable(semaphoreStrategies, WARNING_CLASS);
	jsp.setBorder(new TitledBorder(new EtchedBorder(), "Semaphore Strategies"));
	mainPanel.setResizeWeight(1.0);
	jsp.setMinimumSize(new Dimension(200, 100));
	mainPanel.setLeftComponent(jsp);
	semaphoreEditor.setMinimumSize(new Dimension(225, 100));
	mainPanel.setRightComponent(semaphoreEditor);
	add(mainPanel, BorderLayout.CENTER);
}
 
開發者ID:max6cn,項目名稱:jmt,代碼行數:17,代碼來源:SemaphoreSectionPanel.java

示例4: initComponents

import javax.swing.JSplitPane; //導入方法依賴的package包/類
protected void initComponents() {
	this.setLayout(new BorderLayout());
	//building mainPanel
	mainPanel = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT);
	mainPanel.setDividerSize(4);
	mainPanel.setBorder(new EmptyBorder(5, 5, 5, 5));
	//layout of main panel
	WarningScrollTable jsp = new WarningScrollTable(routingStrategies, WARNING_CLASS);
	jsp.setBorder(new TitledBorder(new EtchedBorder(), "Routing Strategies"));
	mainPanel.setResizeWeight(1.0);
	jsp.setMinimumSize(new Dimension(200, 100));
	mainPanel.setLeftComponent(jsp);
	routingProbEditor.setMinimumSize(new Dimension(225, 100));
	mainPanel.setRightComponent(routingProbEditor);
	add(mainPanel, BorderLayout.CENTER);
}
 
開發者ID:max6cn,項目名稱:jmt,代碼行數:17,代碼來源:RoutingSectionPanel.java

示例5: setup_child_split_pane_left

import javax.swing.JSplitPane; //導入方法依賴的package包/類
private void setup_child_split_pane_left(final JSplitPane split_pane) {
	JScrollPane quantum_system_scroll_pane = new JScrollPane();
	split_pane.setLeftComponent(quantum_system_scroll_pane);
	
	JPanel quantum_system_panel = new JPanel();
	quantum_system_scroll_pane.setViewportView(quantum_system_panel);
	
	qubit_table = new QubitTable(gate_table_row_height);		
	GridBagConstraints gbc_qubit_table = new GridBagConstraints();
	gbc_qubit_table.gridx = 0;
	gbc_qubit_table.gridy = 0;
	quantum_system_panel.add(qubit_table, gbc_qubit_table);
	
	gate_table = new GateTable(gate_table_cell_size, gate_table_row_height, frame);
	GridBagConstraints gbc_gate_table = new GridBagConstraints();
	gbc_gate_table.gridx = 1;
	gbc_gate_table.gridy = 0;
	quantum_system_panel.add(gate_table, gbc_gate_table);
	
	GridBagLayout gbl_quantum_system_panel = new GridBagLayout();
	gbl_quantum_system_panel.columnWidths = new int[]{qubit_table.getWidth(), gate_table.getWidth(), 0};
	gbl_quantum_system_panel.rowHeights = new int[]{qubit_table.getHeight(), 0};
	gbl_quantum_system_panel.columnWeights = new double[]{0.0, 0.0, Double.MIN_VALUE};
	gbl_quantum_system_panel.rowWeights = new double[]{0.0, Double.MIN_VALUE};
	quantum_system_panel.setLayout(gbl_quantum_system_panel);
}
 
開發者ID:QwertygidQ,項目名稱:DeutschSim,代碼行數:27,代碼來源:GUI.java

示例6: initComponents

import javax.swing.JSplitPane; //導入方法依賴的package包/類
protected void initComponents() {
	this.setLayout(new BorderLayout());
	//building mainPanel
	mainPanel = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT);
	mainPanel.setDividerSize(4);
	mainPanel.setBorder(new EmptyBorder(5, 5, 5, 5));
	//layout of main panel
	WarningScrollTable jsp = new WarningScrollTable(routingStrategies, WARNING_CLASS);
	//routing strategy selector on the left, routing probabilities editor on the right
	jsp.setBorder(new TitledBorder(new EtchedBorder(), "Routing Strategies"));
	mainPanel.setResizeWeight(.80); // Gives more space to left component
	jsp.setMinimumSize(new Dimension(180, 100));
	mainPanel.setLeftComponent(jsp);
	routingProbEditor.setMinimumSize(new Dimension(160, 100));
	mainPanel.setRightComponent(routingProbEditor);
	add(mainPanel, BorderLayout.CENTER);
}
 
開發者ID:HOMlab,項目名稱:QN-ACTR-Release,代碼行數:18,代碼來源:RoutingSectionPanel.java

示例7: initAssetsComponent

import javax.swing.JSplitPane; //導入方法依賴的package包/類
private static Component initAssetsComponent() {
  JSplitPane split = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT);
  AssetTree tree = new AssetTree();
  split.setLeftComponent(tree);
  assetPanel = new AssetPanel();

  JScrollPane scrollPane = new JScrollPane(assetPanel);

  split.addPropertyChangeListener(JSplitPane.DIVIDER_LOCATION_PROPERTY, evt -> userPreferences.setAssetsSplitter(split.getDividerLocation()));
  split.setDividerLocation(userPreferences.getMainSplitterPosition() != 0 ? userPreferences.getAssetsSplitter() : 200);

  split.setRightComponent(scrollPane);
  return split;
}
 
開發者ID:gurkenlabs,項目名稱:litiengine,代碼行數:15,代碼來源:Program.java

示例8: addComponentsToContainer

import javax.swing.JSplitPane; //導入方法依賴的package包/類
/** Adds real components to given container (according to layout
   * constraints stored for the components).
   * @param container instance of a real container to be added to
   * @param containerDelegate effective container delegate of the container
   * @param components components to be added
   * @param index position at which to add the components to container
   */
  @Override
  public void addComponentsToContainer(Container container,
                                       Container containerDelegate,
                                       Component[] components,
                                       int index)
  {
      if (!(container instanceof JSplitPane))
          return;	
	
      for (int i=0; i < components.length; i++) {	    	    
   JSplitPane splitPane = (JSplitPane) container;
   
          int descPos = convertPosition(getConstraints(i + index));
          if (descPos == 0) {
if(splitPane.getClientProperty(LEFT_TOP_BUTTON)==null) {	    
    // store the defaul swing button, so we can fall back to it 
    // if component[i] will be removed later...
    splitPane.putClientProperty(LEFT_TOP_BUTTON, splitPane.getLeftComponent());  
} 
splitPane.setLeftComponent(components[i]);
   } 
   else if (descPos == 1) {
if(splitPane.getClientProperty(RIGHT_BOTTOM_BUTTON)==null) {
    // store the defaul swing button, so we can fall back to it 
    // if component[i] will be removed later...
    splitPane.putClientProperty(RIGHT_BOTTOM_BUTTON, splitPane.getRightComponent());	    	    	    
} 							    				
splitPane.setRightComponent(components[i]);	    
   }
              
      }	
  }
 
開發者ID:apache,項目名稱:incubator-netbeans,代碼行數:40,代碼來源:JSplitPaneSupport.java

示例9: initialize

import javax.swing.JSplitPane; //導入方法依賴的package包/類
/**
 * This method initializes this
 *
 * @return void
 */
private void initialize() {
    setLayout(new BorderLayout());
    this.setSize(new Dimension(441, 231));
    JSplitPane splitPane = new JSplitPane();
    this.add(splitPane, java.awt.BorderLayout.CENTER);
    splitPane.setOrientation(JSplitPane.VERTICAL_SPLIT);
    splitPane.setDividerLocation(0.75d);
    splitPane.setLeftComponent(getSelectRowPane());
    splitPane.setRightComponent(getJPanel4());
}
 
開發者ID:Vitaliy-Yakovchuk,項目名稱:ramus,代碼行數:16,代碼來源:SectorRowsEditor.java

示例10: initialize

import javax.swing.JSplitPane; //導入方法依賴的package包/類
private void initialize() {
	this.setSize(615, 430);

	final JSplitPane jsp = new JSplitPane();

	jsp.setLeftComponent(createPnlParameter());
	jsp.setRightComponent(createPnlArea());
	jsp.setDividerSize(0);
	jsp.setDividerLocation(201);

	this.setContentPane(jsp);
	this.setVisible(true);
	this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
}
 
開發者ID:tekrei,項目名稱:CoverageGA,代碼行數:15,代碼來源:CoverageFrame.java

示例11: setup_main_split_pane_top

import javax.swing.JSplitPane; //導入方法依賴的package包/類
private JSplitPane setup_main_split_pane_top(final JSplitPane split_pane) {
	JSplitPane child_split_pane = new JSplitPane();
	child_split_pane.setResizeWeight(child_split_pane_resize_weight);
	split_pane.setLeftComponent(child_split_pane);
	
	return child_split_pane;
}
 
開發者ID:QwertygidQ,項目名稱:DeutschSim,代碼行數:8,代碼來源:GUI.java

示例12: init

import javax.swing.JSplitPane; //導入方法依賴的package包/類
private void init() {
    setLayout(new BorderLayout());
    projectNReusableTreeSplitPane = new JSplitPane(JSplitPane.VERTICAL_SPLIT);
    projectNReusableTreeSplitPane.setOneTouchExpandable(true);
    projectNReusableTreeSplitPane.setResizeWeight(0.5);

    projectNReusableTreeSplitPane.setTopComponent(getTreeInPanel("Test Plan", testDesign.getProjectTree().getTree()));

    appReusablePanel = getRTreeInPanel("Reusable Component", testDesign.getReusableTree().getTree());
    projectNReusableTreeSplitPane.setBottomComponent(appReusablePanel);

    testCaseNTestDataSplitPane = new JSplitPane(JSplitPane.VERTICAL_SPLIT);
    testCaseNTestDataSplitPane.setOneTouchExpandable(true);
    testCaseNTestDataSplitPane.setResizeWeight(0.5);

    testCaseNTestDataSplitPane.setTopComponent(testDesign.getTestCaseComponent());
    testCaseNTestDataSplitPane.setBottomComponent(testDesign.getTestDatacomp());

    oneTwo = new JSplitPane();
    oneTwo.setOneTouchExpandable(true);
    oneTwo.setResizeWeight(0.25);

    oneTwo.setLeftComponent(projectNReusableTreeSplitPane);
    oneTwo.setRightComponent(testCaseNTestDataSplitPane);

    oneThree = new JSplitPane();
    oneThree.setOneTouchExpandable(true);
    oneThree.setResizeWeight(0.8);

    oneThree.setLeftComponent(oneTwo);
    oneThree.setRightComponent(testDesign.getObjectRepo());

    add(oneThree);

}
 
開發者ID:CognizantQAHub,項目名稱:Cognizant-Intelligent-Test-Scripter,代碼行數:36,代碼來源:TestDesignUI.java

示例13: RSFViewer2

import javax.swing.JSplitPane; //導入方法依賴的package包/類
public RSFViewer2(final Engine engine) {
    this.engine = engine;
    this.setDefaultCloseOperation(DO_NOTHING_ON_CLOSE);
    this.addWindowListener(new WindowAdapter() {
        @Override
        public void windowClosing(WindowEvent e) {
            try {
                ((FileIEngineImpl) engine.getDeligate()).close();
            } catch (IOException e1) {
                e1.printStackTrace();
            }
            System.exit(0);
        }
    });
    this.setTitle("Ramus files viewer sample 2");

    JSplitPane pane = new JSplitPane();

    pane.setLeftComponent(createQualifiersList());
    pane.setRightComponent(createTreeView());

    this.setContentPane(pane);

    this.pack();
    this.setSize(800, 600);
    this.setLocationRelativeTo(null);
}
 
開發者ID:Vitaliy-Yakovchuk,項目名稱:ramus,代碼行數:28,代碼來源:RSFViewer2.java

示例14: setupPane

import javax.swing.JSplitPane; //導入方法依賴的package包/類
/**
 * Adds content to the primary splitpane.
 */
private void setupPane() {
	// Setup splitpane, will host main content such as the file tree and the
	// tabbed panel which will hold classes and other menus.
	JSplitPane splitPane = new JSplitPane();
	splitPane.setResizeWeight(0.1);
	splitPane.setOneTouchExpandable(true);
	frame.getContentPane().add(splitPane, BorderLayout.CENTER);
	splitPane.setLeftComponent(classTree);
	splitPane.setRightComponent(tabs);
}
 
開發者ID:Col-E,項目名稱:Recaf,代碼行數:14,代碼來源:SwingUI.java

示例15: createGroupPanel

import javax.swing.JSplitPane; //導入方法依賴的package包/類
private JComponent createGroupPanel() {
    JSplitPane pane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT);

    groupTable = new JTable(groupModel) {
        /**
         *
         */
        private static final long serialVersionUID = 5000667220319722662L;


        public void changeSelection(int rowIndex, int columnIndex,
                                    boolean toggle, boolean extend) {
            super.changeSelection(rowIndex, columnIndex, toggle, extend);
            qualifierModel.fireTableDataChanged();
            deleteGroup.setEnabled(rowIndex >= 0);
        }
    };
    JScrollPane scrollPane = new JScrollPane();
    scrollPane.setViewportView(groupTable);

    pane.setLeftComponent(scrollPane);

    JScrollPane pane2 = new JScrollPane();
    qualifiersTable = new JTable(qualifierModel);
    pane2.setViewportView(qualifiersTable);
    pane.setRightComponent(pane2);
    pane.setDividerLocation(400);
    return pane;
}
 
開發者ID:Vitaliy-Yakovchuk,項目名稱:ramus,代碼行數:30,代碼來源:EditUsersDialog.java


注:本文中的javax.swing.JSplitPane.setLeftComponent方法示例由純淨天空整理自Github/MSDocs等開源代碼及文檔管理平台,相關代碼片段篩選自各路編程大神貢獻的開源項目,源碼版權歸原作者所有,傳播和使用請參考對應項目的License;未經允許,請勿轉載。