Search in sources :

Example 11 with JPanel

use of javax.swing.JPanel in project qi4j-sdk by Qi4j.

the class APIPane method $$$setupUI$$$.

/**
     * Method generated by IntelliJ IDEA GUI Designer
     * >>> IMPORTANT!! <<<
     * DO NOT edit this method OR call it in your code!
     *
     */
private void $$$setupUI$$$() {
    contentPane = new JPanel();
    contentPane.setLayout(new BorderLayout(0, 0));
    final JScrollPane scrollPane1 = new JScrollPane();
    contentPane.add(scrollPane1, BorderLayout.CENTER);
    apiTable = new JTable();
    apiTable.setShowVerticalLines(true);
    scrollPane1.setViewportView(apiTable);
}
Also used : JScrollPane(javax.swing.JScrollPane) JPanel(javax.swing.JPanel) BorderLayout(java.awt.BorderLayout) JTable(javax.swing.JTable)

Example 12 with JPanel

use of javax.swing.JPanel in project qi4j-sdk by Qi4j.

the class DependencyPane method $$$setupUI$$$.

/**
     * Method generated by IntelliJ IDEA GUI Designer
     * >>> IMPORTANT!! <<<
     * DO NOT edit this method OR call it in your code!
     *
     */
private void $$$setupUI$$$() {
    contentPane = new JPanel();
    contentPane.setLayout(new BorderLayout(0, 0));
    splitPane = new JSplitPane();
    contentPane.add(splitPane, BorderLayout.CENTER);
    final JScrollPane scrollPane1 = new JScrollPane();
    splitPane.setLeftComponent(scrollPane1);
    fieldList = new JList();
    scrollPane1.setViewportView(fieldList);
    detailPane = new JPanel();
    detailPane.setLayout(new GridBagLayout());
    splitPane.setRightComponent(detailPane);
    detailPane.setBorder(BorderFactory.createTitledBorder(BorderFactory.createEmptyBorder(8, 8, 8, 8), null));
    final JLabel label1 = new JLabel();
    this.$$$loadLabelText$$$(label1, ResourceBundle.getBundle("org/qi4j/envisage/detail/DependencyPane").getString("CTL_ClassName.Text"));
    GridBagConstraints gbc;
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 0;
    gbc.anchor = GridBagConstraints.EAST;
    detailPane.add(label1, gbc);
    final JPanel spacer1 = new JPanel();
    gbc = new GridBagConstraints();
    gbc.gridx = 1;
    gbc.gridy = 0;
    gbc.fill = GridBagConstraints.HORIZONTAL;
    detailPane.add(spacer1, gbc);
    final JPanel spacer2 = new JPanel();
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 1;
    gbc.fill = GridBagConstraints.VERTICAL;
    detailPane.add(spacer2, gbc);
    final JLabel label2 = new JLabel();
    this.$$$loadLabelText$$$(label2, ResourceBundle.getBundle("org/qi4j/envisage/detail/DependencyPane").getString("CTL_Optional.Text"));
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 2;
    gbc.anchor = GridBagConstraints.EAST;
    detailPane.add(label2, gbc);
    final JLabel label3 = new JLabel();
    this.$$$loadLabelText$$$(label3, ResourceBundle.getBundle("org/qi4j/envisage/detail/DependencyPane").getString("CTL_Annotation.Text"));
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 4;
    gbc.anchor = GridBagConstraints.EAST;
    detailPane.add(label3, gbc);
    final JPanel spacer3 = new JPanel();
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 3;
    gbc.fill = GridBagConstraints.VERTICAL;
    detailPane.add(spacer3, gbc);
    final JPanel spacer4 = new JPanel();
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 5;
    gbc.fill = GridBagConstraints.VERTICAL;
    detailPane.add(spacer4, gbc);
    final JPanel spacer5 = new JPanel();
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 9;
    gbc.fill = GridBagConstraints.VERTICAL;
    detailPane.add(spacer5, gbc);
    final JLabel label4 = new JLabel();
    this.$$$loadLabelText$$$(label4, ResourceBundle.getBundle("org/qi4j/envisage/detail/DependencyPane").getString("CTL_InjectionType.Text"));
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 10;
    gbc.anchor = GridBagConstraints.EAST;
    detailPane.add(label4, gbc);
    classNameLabel = new JLabel();
    classNameLabel.setText("none");
    gbc = new GridBagConstraints();
    gbc.gridx = 2;
    gbc.gridy = 0;
    gbc.weightx = 1.0;
    gbc.anchor = GridBagConstraints.WEST;
    detailPane.add(classNameLabel, gbc);
    annotationLabel = new JLabel();
    annotationLabel.setText("none");
    gbc = new GridBagConstraints();
    gbc.gridx = 2;
    gbc.gridy = 4;
    gbc.anchor = GridBagConstraints.WEST;
    detailPane.add(annotationLabel, gbc);
    injectionTypeLabel = new JLabel();
    injectionTypeLabel.setText("none");
    gbc = new GridBagConstraints();
    gbc.gridx = 2;
    gbc.gridy = 10;
    gbc.anchor = GridBagConstraints.WEST;
    detailPane.add(injectionTypeLabel, gbc);
    optionalLabel = new JLabel();
    optionalLabel.setText("none");
    gbc = new GridBagConstraints();
    gbc.gridx = 2;
    gbc.gridy = 2;
    gbc.anchor = GridBagConstraints.WEST;
    detailPane.add(optionalLabel, gbc);
    final JPanel spacer6 = new JPanel();
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 7;
    gbc.fill = GridBagConstraints.VERTICAL;
    detailPane.add(spacer6, gbc);
    final JLabel label5 = new JLabel();
    this.$$$loadLabelText$$$(label5, ResourceBundle.getBundle("org/qi4j/envisage/detail/DependencyPane").getString("CTL_Injection.Text"));
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 8;
    gbc.anchor = GridBagConstraints.WEST;
    detailPane.add(label5, gbc);
    final JScrollPane scrollPane2 = new JScrollPane();
    gbc = new GridBagConstraints();
    gbc.gridx = 2;
    gbc.gridy = 12;
    gbc.weighty = 1.0;
    gbc.fill = GridBagConstraints.BOTH;
    detailPane.add(scrollPane2, gbc);
    injectedServiceList = new JList();
    scrollPane2.setViewportView(injectedServiceList);
    final JPanel spacer7 = new JPanel();
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 11;
    gbc.fill = GridBagConstraints.VERTICAL;
    detailPane.add(spacer7, gbc);
    final JLabel label6 = new JLabel();
    this.$$$loadLabelText$$$(label6, ResourceBundle.getBundle("org/qi4j/envisage/detail/DependencyPane").getString("CTL_InjectedServices.Text"));
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 12;
    gbc.anchor = GridBagConstraints.NORTHEAST;
    detailPane.add(label6, gbc);
    final JSeparator separator1 = new JSeparator();
    gbc = new GridBagConstraints();
    gbc.gridx = 0;
    gbc.gridy = 6;
    gbc.gridwidth = 3;
    gbc.fill = GridBagConstraints.BOTH;
    detailPane.add(separator1, gbc);
}
Also used : JScrollPane(javax.swing.JScrollPane) JPanel(javax.swing.JPanel) GridBagConstraints(java.awt.GridBagConstraints) BorderLayout(java.awt.BorderLayout) GridBagLayout(java.awt.GridBagLayout) JLabel(javax.swing.JLabel) JSplitPane(javax.swing.JSplitPane) JList(javax.swing.JList) JSeparator(javax.swing.JSeparator)

Example 13 with JPanel

use of javax.swing.JPanel in project qi4j-sdk by Qi4j.

the class EnvisageFrame method $$$setupUI$$$.

/**
     * Method generated by IntelliJ IDEA GUI Designer
     * >>> IMPORTANT!! <<<
     * DO NOT edit this method OR call it in your code!
     *
     */
private void $$$setupUI$$$() {
    contentPane = new JPanel();
    contentPane.setLayout(new BorderLayout(0, 0));
}
Also used : JPanel(javax.swing.JPanel) BorderLayout(java.awt.BorderLayout)

Example 14 with JPanel

use of javax.swing.JPanel in project pcgen by PCGen.

the class InfoGuidePane method initComponents.

private void initComponents() {
    mainPanel = new JPanel();
    mainPanel.setBorder(BorderFactory.createTitledBorder(null, "", TitledBorder.CENTER, TitledBorder.DEFAULT_POSITION, null));
    mainPanel.setLayout(new BoxLayout(mainPanel, BoxLayout.Y_AXIS));
    mainPanel.setPreferredSize(new Dimension(650, 450));
    setOpaque(false);
    JPanel sourcesPanel = new JPanel(new GridBagLayout());
    GridBagConstraints gbc1 = new GridBagConstraints();
    gbc1.anchor = GridBagConstraints.EAST;
    GridBagConstraints gbc2 = new GridBagConstraints();
    gbc2.gridwidth = GridBagConstraints.REMAINDER;
    gbc2.fill = GridBagConstraints.BOTH;
    sourcesPanel.add(new JLabel(LanguageBundle.getString("in_si_intro")), gbc2);
    sourcesPanel.add(new JLabel(LanguageBundle.getString("in_si_gamemode")), gbc1);
    sourcesPanel.add(gameModeLabel, gbc2);
    sourcesPanel.add(new JLabel(LanguageBundle.getString("in_si_sources")), gbc1);
    sourcesPanel.add(campaignList, gbc2);
    JEditorPane guidePane = createHtmlPane();
    guidePane.setText(LanguageBundle.getFormattedString("in_si_whatnext", Icons.New16.getImageIcon(), Icons.Open16.getImageIcon()));
    mainPanel.add(sourcesPanel);
    mainPanel.add(guidePane);
    mainPanel.add(tipPane);
    refreshDisplayedSources(null);
    JPanel outerPanel = new JPanel(new FlowLayout());
    outerPanel.add(mainPanel);
    setLayout(new BorderLayout());
    add(outerPanel, BorderLayout.CENTER);
    tipPane.setText(LanguageBundle.getFormattedString("in_si_tip", TipOfTheDayHandler.getInstance().getNextTip()));
}
Also used : JPanel(javax.swing.JPanel) GridBagConstraints(java.awt.GridBagConstraints) FlowLayout(java.awt.FlowLayout) GridBagLayout(java.awt.GridBagLayout) BorderLayout(java.awt.BorderLayout) BoxLayout(javax.swing.BoxLayout) JEditorPane(javax.swing.JEditorPane) JLabel(javax.swing.JLabel) Dimension(java.awt.Dimension)

Example 15 with JPanel

use of javax.swing.JPanel in project pcgen by PCGen.

the class PCGenFrame method maybeShowWarningConfirm.

@Override
public Boolean maybeShowWarningConfirm(String title, String message, String checkBoxText, final PropertyContext context, final String contextProp) {
    if (!context.getBoolean(contextProp, true)) {
        return null;
    }
    final JCheckBox checkBox = new JCheckBox(checkBoxText, true);
    checkBox.addItemListener(new ItemListener() {

        @Override
        public void itemStateChanged(ItemEvent e) {
            context.setBoolean(contextProp, checkBox.isSelected());
        }
    });
    JPanel panel = buildMessageLabelPanel(message, checkBox);
    int ret = JOptionPane.showConfirmDialog(this, panel, title, JOptionPane.YES_NO_OPTION, JOptionPane.WARNING_MESSAGE);
    return ret == JOptionPane.YES_OPTION;
}
Also used : JCheckBox(javax.swing.JCheckBox) JPanel(javax.swing.JPanel) ItemEvent(java.awt.event.ItemEvent) ItemListener(java.awt.event.ItemListener)

Aggregations

JPanel (javax.swing.JPanel)4464 JLabel (javax.swing.JLabel)1842 BorderLayout (java.awt.BorderLayout)1454 JButton (javax.swing.JButton)1174 Dimension (java.awt.Dimension)1097 GridBagLayout (java.awt.GridBagLayout)1071 ActionEvent (java.awt.event.ActionEvent)1013 GridBagConstraints (java.awt.GridBagConstraints)954 JScrollPane (javax.swing.JScrollPane)901 ActionListener (java.awt.event.ActionListener)865 BoxLayout (javax.swing.BoxLayout)792 Insets (java.awt.Insets)724 FlowLayout (java.awt.FlowLayout)667 JTextField (javax.swing.JTextField)532 JCheckBox (javax.swing.JCheckBox)456 GridLayout (java.awt.GridLayout)375 JComboBox (javax.swing.JComboBox)268 EmptyBorder (javax.swing.border.EmptyBorder)252 JTable (javax.swing.JTable)224 Color (java.awt.Color)210