Class PropertiesPanel

All Implemented Interfaces:
ImageObserver, MenuContainer, Serializable, Accessible

public class PropertiesPanel extends JPanel
Panel for showing properties. Provides reusable code for grid bag layout.
See Also:
  • Field Details

    • gbc

      protected GridBagConstraints gbc
      The grid bag constraints.
    • dummy

      protected JComponent dummy
      The last component for extra space.
    • components

      protected Map components
      The created components (name->comp).
    • adddummy

      protected boolean adddummy
      Add dummy when weighty==0.
  • Constructor Details

    • PropertiesPanel

      public PropertiesPanel()
      Create new properties panel.
    • PropertiesPanel

      public PropertiesPanel(String title)
      Create new properties panel.
  • Method Details

    • getTextField

      public JTextField getTextField(String name)
      Get a text field.
    • getComponent

      public JComponent getComponent(String name)
      Get a component.
    • getCheckBox

      public JCheckBox getCheckBox(String name)
      Get a check box.
    • getComboBox

      public JComboBox getComboBox(String name)
      Get a combo box.
    • createTextField

      public JTextField createTextField(String name)
      Create a text field and add it to the panel.
    • createTextField

      public JTextField createTextField(String name, String defvalue)
      Create a text field and add it to the panel.
    • createTextField

      public JTextField createTextField(String name, String defvalue, boolean editable)
      Create a text field and add it to the panel.
    • createTextField

      public JTextField createTextField(String name, String defvalue, boolean editable, double weighty)
      Create a text field and add it to the panel.
    • createTextField

      public JTextField createTextField(String name, String defvalue, boolean editable, double weighty, String tooltip)
      Create a text field and add it to the panel.
    • createCheckBox

      public JCheckBox createCheckBox(String name)
      Create a check box and add it to the panel.
    • createCheckBox

      public JCheckBox createCheckBox(String name, boolean selected, boolean enabled)
      Create a check box and add it to the panel.
    • createCheckBox

      public JCheckBox createCheckBox(String name, boolean selected, boolean enabled, double weighty)
      Create a check box and add it to the panel.
    • createCheckBox

      public JCheckBox createCheckBox(String name, boolean selected, boolean enabled, double weighty, String tooltip)
      Create a check box and add it to the panel.
    • createComboBox

      public JComboBox createComboBox(String name, Object[] values)
      Create a combo box and add it to the panel.
    • createComboBox

      public JComboBox createComboBox(String name, Object[] values, boolean editable, double weighty)
      Create a combo box and add it to the panel.
    • createButton

      public JButton createButton(String name, String text)
      Create a button and add it to the panel.
    • createButton

      public JButton createButton(String name, String text, double weighty)
      Create a button and add it to the panel.
    • createButtons

      public JButton[] createButtons(String groupname, String[] names, double weighty)
      Create several buttons.
      Parameters:
      names - The button names.
    • addComponent

      public void addComponent(String name, JComponent comp)
      Add a component that spans a full line. No label is rendered.
    • addComponent

      public void addComponent(String name, JComponent comp, double weighty)
      Add a component
    • addComponent

      public void addComponent(String name, JComponent comp, double weighty, int fill)
      Add a component
    • addComponent

      public void addComponent(String name, JComponent comp, double weighty, int fill, int anchor, String tooltip)
      Add a component
    • addFullLineComponent

      public void addFullLineComponent(String name, JComponent comp)
      Add a component that spans a full line. No label is rendered.
    • addFullLineComponent

      public void addFullLineComponent(String name, JComponent comp, double weighty)
      Add a component that spans a full line. No label is rendered.