Class ToolButton

All Implemented Interfaces:
ActionListener, ImageObserver, ItemSelectable, MenuContainer, Serializable, EventListener, Accessible, SwingConstants, GraffitiComponent, GraffitiContainer, GraffitiToolComponent

public class ToolButton
extends GraffitiToggleButton
implements GraffitiToolComponent, ActionListener
DOCUMENT ME!
Version:
$Revision: 1.11 $ $Date: 2010/12/22 13:05:54 $
Author:
$Author: klukas $
See Also:
Serialized Form
  • Constructor Details

    • ToolButton

      public ToolButton​(Tool t)
      Constructor that sets the buttons tool to the given Tool.
      Parameters:
      t - DOCUMENT ME!
    • ToolButton

      public ToolButton​(Tool t, String preferredComponent)
      Creates a new ToolButton object.
      Parameters:
      t - DOCUMENT ME!
      preferredComponent - DOCUMENT ME!
    • ToolButton

      public ToolButton​(Tool t, String preferredComponent, ImageIcon icon)
      Creates a new ToolButton object.
      Parameters:
      t - DOCUMENT ME!
      preferredComponent - DOCUMENT ME!
      icon - DOCUMENT ME!
    • ToolButton

      public ToolButton​(Tool t, String preferredComponent, String text)
      Creates a new ToolButton object.
      Parameters:
      t - DOCUMENT ME!
      preferredComponent - DOCUMENT ME!
      text - DOCUMENT ME!
  • Method Details

    • checkStatusForAllToolButtons

      public static void checkStatusForAllToolButtons()
    • requestToolButtonFocus

      public static void requestToolButtonFocus()
    • getId

      public String getId()
      Description copied from interface: GraffitiContainer
      Returns an unique identifier for this GraffitiComponent.
      Specified by:
      getId in interface GraffitiContainer
      Returns:
      an unique identifier for this GraffitiComponent.
      See Also:
      GraffitiContainer.getId()
    • getTool

      public Tool getTool()
      Returns the tool this button is identified with.
      Specified by:
      getTool in interface GraffitiToolComponent
      Returns:
      the tool this button is identified with.
    • actionPerformed

      public void actionPerformed​(ActionEvent arg0)
      Specified by:
      actionPerformed in interface ActionListener
    • addKnownModeToolBar

      public static void addKnownModeToolBar​(ModeToolbar toolbar)
      Parameters:
      toolbar -