Class JaxoButtonPanel

All Implemented Interfaces:
ImageObserver, MenuContainer, PropertyChangeListener, Serializable, EventListener, Accessible, JaxoLocalized

public class JaxoButtonPanel extends JPanel implements PropertyChangeListener, JaxoLocalized
The menu bar that holds the file, edit, options and help menus.
Since:
2.0
See Also:
  • Field Details

    • RAISED_ETCHED_BORDER

      public static final EtchedBorder RAISED_ETCHED_BORDER
      The raised etched border of all the panels holding the buttons.
    • BUTTON_CONSTRAINTS

      public static final GridBagConstraints BUTTON_CONSTRAINTS
      The layout constraints of the buttons.
  • Constructor Details

    • JaxoButtonPanel

      public JaxoButtonPanel(ActionListener l)
      Constructs the button panel. Adds particle, edit, misc, action and grid button panels.
      Parameters:
      l - The ActionListener to receive events from this ButtonPanel.
  • Method Details

    • paintBorder

      protected void paintBorder(Graphics g)
      Paints additional etched lines in the middle between the children.
      Overrides:
      paintBorder in class JComponent
      Parameters:
      g - the graphics context.
    • propertyChange

      public void propertyChange(PropertyChangeEvent e)
      Applies a property change event.
      Specified by:
      propertyChange in interface PropertyChangeListener
      Parameters:
      e - the change event.
    • updateLanguage

      public final void updateLanguage()
      Updates the component with the current language as set in the preferences (JaxoPrefs.PREF_LANGUAGE).
      Specified by:
      updateLanguage in interface JaxoLocalized
    • setDefault

      public final void setDefault(int mode)
      Set a button as default.
      Parameters:
      mode - An integer defined in JaxoConstants specifying the mode to be set as default. Just delegates to the individual button panels.
    • pressButton

      public final void pressButton(int mode)
      Presses a button.
      Parameters:
      mode - An integer defined in JaxoConstants specifying the button to be pressed. Just delegates to the individual button panels.