Package javax.swing

Examples of javax.swing.JSplitPane


    pnlFields.add(new JLabel("User Date of Birth"));
    pnlFields.add(userDOB);

    pnlEditorArea.add(pnlFields, BorderLayout.NORTH);
    JSplitPane splitPane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, new JScrollPane(lstUsers), new JScrollPane(pnlEditorArea));
    splitPane.setDividerLocation(200);
    add(splitPane, BorderLayout.CENTER);
  }
View Full Code Here


    tab.addTab("Contacts", new JScrollPane(contactList));
    tab.addTab("Files", scrollPaneFiles);

    pnlEditorArea.add(tab, BorderLayout.CENTER);

    JSplitPane splitPane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, new JScrollPane(lstProjects), pnlEditorArea);
    splitPane.setDividerLocation(200);
    add(splitPane, BorderLayout.CENTER);
  }
View Full Code Here

    tab.addTab("Contacts", new JScrollPane(contactList));
    tab.addTab("Files", scrollPaneFiles);

    pnlEditorArea.add(tab, BorderLayout.CENTER);

    JSplitPane splitPane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, new JScrollPane(lstProjects), pnlEditorArea);
    splitPane.setDividerLocation(200);
    add(splitPane, BorderLayout.CENTER);
  }
View Full Code Here

        initComponents(window);
        initEventHandling(window);
       
        JPanel leftPane=buildLeftPane(window);
        JPanel rightPane=buildRightPane(window);
        JSplitPane splitPane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, leftPane, rightPane);
        splitPane.setOneTouchExpandable(true);
//        splitPane.setResizeWeight(0.1);
       
        FormLayout layout = new FormLayout(
                "10dlu,fill:p:grow",
                "10dlu,fill:p:grow,3dlu,p");
View Full Code Here

  public Component buildPanel(WindowInterface window) {
    initComponents(window);
    initEventHandling(window);
    JPanel leftPane = buildLeftPane(window);
    JPanel rightPane = buildRightPane(window);
    JSplitPane splitPane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT,
        leftPane, rightPane);
    splitPane.setOneTouchExpandable(true);
    splitPane.setResizeWeight(0.5);

    FormLayout layout = new FormLayout("10dlu,fill:p:grow",
        "10dlu,fill:p:grow,3dlu,p,3dlu");
    PanelBuilder builder = new PanelBuilder(layout);
//     PanelBuilder builder = new PanelBuilder(new FormDebugPanel(),layout);
View Full Code Here

    tabbedPane.addTab("PHP Generator", IconUtils.createImageIcon(ICON_CLASS_PATH + "application_x_php.png"), new JLabel("PHP代码生成器,开发中..."), "PHP代码生成器");
    tabbedPane.addTab("ASP.Net Generator", IconUtils.createImageIcon(ICON_CLASS_PATH + "filetype_asp.png"), new JLabel("ASP.Net代码生成器,开发中..."), "ASP.Net代码生成器");
    tabbedPane.addTab("C# Generator", IconUtils.createImageIcon(ICON_CLASS_PATH + "text_x_csharp.png"), new JLabel("C#代码生成器,开发中..."), "C#代码生成器");
    tabbedPane.addTab("Code Preview", IconUtils.createImageIcon(ICON_CLASS_PATH + "view_source.png"), buildCodePreviewPanel(), "代码预览");
   
    JSplitPane centerSplitPane = new JSplitPane(JSplitPane.VERTICAL_SPLIT, true, metadataTableScrollPane, tabbedPane);
    centerSplitPane.setBorder(BorderFactory.createEmptyBorder(0, 0, 0, 0));
    centerSplitPane.setDividerLocation(160);
    centerSplitPane.setDividerSize(5)//分隔线的宽度
    centerSplitPane.setOneTouchExpandable(true);
   
    return centerSplitPane;
  }
View Full Code Here

    addGrid(panel, fCounterPanel,   0, 4, 2, GridBagConstraints.NONE,       0.0, GridBagConstraints.WEST);
    addGrid(panel, new JSeparator(),   0, 5, 2, GridBagConstraints.HORIZONTAL, 1.0, GridBagConstraints.WEST);
    addGrid(panel, new JLabel("Results:")0, 6, 2, GridBagConstraints.HORIZONTAL,   1.0, GridBagConstraints.WEST);

    JSplitPane splitter= new JSplitPane(JSplitPane.VERTICAL_SPLIT, fTestViewTab, tracePane);
    addGrid(panel, splitter,    0, 7, 2, GridBagConstraints.BOTH,       1.0, GridBagConstraints.WEST);

    addGrid(panel, failedPanel,    2, 7, 1, GridBagConstraints.HORIZONTAL,   0.0, GridBagConstraints.NORTH/*CENTER*/);

    addGrid(panel, fStatusLine,    0, 9, 2, GridBagConstraints.HORIZONTAL,   1.0, GridBagConstraints.CENTER);
View Full Code Here

    initPlugins(pluginRegistry);

    getContentPane().add(toolbar, BorderLayout.NORTH);
    getContentPane().add(statusBar, BorderLayout.SOUTH);

    mainReceiverSplitPane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, panePanel, receiversPanel);
    dividerSize = mainReceiverSplitPane.getDividerSize();
    mainReceiverSplitPane.setDividerLocation(-1);

    getContentPane().add(mainReceiverSplitPane, BorderLayout.CENTER);
View Full Code Here

    statusLabelPanel.add(upperPanel, BorderLayout.CENTER);
    eventsAndStatusPanel.add(statusLabelPanel, BorderLayout.NORTH);

    lowerPanel =
      new JSplitPane(
        JSplitPane.VERTICAL_SPLIT, eventsAndStatusPanel, detailPanel);

    dividerSize = lowerPanel.getDividerSize();
    lowerPanel.setDividerLocation(-1);

    lowerPanel.setResizeWeight(1.0);
    lowerPanel.setBorder(null);
    lowerPanel.setContinuousLayout(true);

    if (preferenceModel.isDetailPaneVisible()) {
      showDetailPane();
    } else {
      hideDetailPane();
    }
   
    /*
     * Detail panel layout editor
     */
    final JToolBar detailToolbar = new JToolBar(SwingConstants.HORIZONTAL);
    detailToolbar.setFloatable(false);

    final LayoutEditorPane layoutEditorPane = new LayoutEditorPane();
    final JDialog layoutEditorDialog =
      new JDialog((JFrame) null, "Pattern Editor");
    layoutEditorDialog.getContentPane().add(layoutEditorPane);
    layoutEditorDialog.setSize(640, 480);

    layoutEditorPane.addCancelActionListener(
      new ActionListener() {
        public void actionPerformed(ActionEvent e) {
          layoutEditorDialog.setVisible(false);
        }
      });

    layoutEditorPane.addOkActionListener(
      new ActionListener() {
        public void actionPerformed(ActionEvent e) {
          setDetailPaneConversionPattern(
            layoutEditorPane.getConversionPattern());
          layoutEditorDialog.setVisible(false);
        }
      });

    Action editDetailAction =
      new AbstractAction(
        "Edit...", new ImageIcon(ChainsawIcons.ICON_EDIT_RECEIVER)) {
        public void actionPerformed(ActionEvent e) {
          layoutEditorPane.setConversionPattern(
            getDetailPaneConversionPattern());

          Dimension size = Toolkit.getDefaultToolkit().getScreenSize();
          Point p =
            new Point(
              ((int) ((size.getWidth() / 2)
              - (layoutEditorDialog.getSize().getWidth() / 2))),
              ((int) ((size.getHeight() / 2)
              - (layoutEditorDialog.getSize().getHeight() / 2))));
          layoutEditorDialog.setLocation(p);

          layoutEditorDialog.setVisible(true);
        }
      };

    editDetailAction.putValue(
      Action.SHORT_DESCRIPTION,
      "opens a Dialog window to Edit the Pattern Layout text");

    final SmallButton editDetailButton = new SmallButton(editDetailAction);
    editDetailButton.setText(null);
    detailToolbar.add(Box.createHorizontalGlue());
    detailToolbar.add(editDetailButton);
    detailToolbar.addSeparator();
    detailToolbar.add(Box.createHorizontalStrut(5));

    Action closeDetailAction =
      new AbstractAction(null, LineIconFactory.createCloseIcon()) {
        public void actionPerformed(ActionEvent arg0) {
          preferenceModel.setDetailPaneVisible(false);
        }
      };

    closeDetailAction.putValue(
      Action.SHORT_DESCRIPTION, "Hides the Detail Panel");

    SmallButton closeDetailButton = new SmallButton(closeDetailAction);
    detailToolbar.add(closeDetailButton);

    detailPanel.add(detailToolbar, BorderLayout.NORTH);

    JPopupMenu editDetailPopupMenu = new JPopupMenu();
    editDetailPopupMenu.add(editDetailAction);
    editDetailPopupMenu.addSeparator();

    final ButtonGroup layoutGroup = new ButtonGroup();

    JRadioButtonMenuItem defaultLayoutRadio =
      new JRadioButtonMenuItem(
        new AbstractAction("Set to Default Layout") {
          public void actionPerformed(ActionEvent e) {
            setDetailPaneConversionPattern(
              DefaultLayoutFactory.getDefaultPatternLayout());
          }
        });
    editDetailPopupMenu.add(defaultLayoutRadio);
    layoutGroup.add(defaultLayoutRadio);
    defaultLayoutRadio.setSelected(true);

    JRadioButtonMenuItem tccLayoutRadio =
      new JRadioButtonMenuItem(
        new AbstractAction("Set to TCCLayout") {
          public void actionPerformed(ActionEvent e) {
            setDetailPaneConversionPattern(
              PatternLayout.TTCC_CONVERSION_PATTERN);
          }
        });
    editDetailPopupMenu.add(tccLayoutRadio);
    layoutGroup.add(tccLayoutRadio);

    PopupListener editDetailPopupListener =
      new PopupListener(editDetailPopupMenu);
    detail.addMouseListener(editDetailPopupListener);

    /*
     * Logger tree splitpane definition
     */
    nameTreeAndMainPanelSplit = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, logTreePanel, lowerPanel);
   
    nameTreeAndMainPanelSplit.setToolTipText("Still under development....");
    nameTreeAndMainPanelSplit.setDividerLocation(-1);

    add(nameTreeAndMainPanelSplit, BorderLayout.CENTER);
View Full Code Here

                    points = createCross();
                    paintConvexHull();
                }
            });

            JSplitPane splitpane = new JSplitPane(JSplitPane.HORIZONTAL_SPLIT, container, controlPanel);
            splitpane.setDividerLocation(600);

            add(splitpane);
           
            points = createRandomPoints(1000);
            paintConvexHull();
View Full Code Here

TOP

Related Classes of javax.swing.JSplitPane

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.