JavaTM 2 Platform
Std. Ed. v1.3.1

javax.swing.plaf.basic
Class BasicToolBarUI

java.lang.Object
  |
  +--javax.swing.plaf.ComponentUI
        |
        +--javax.swing.plaf.ToolBarUI
              |
              +--javax.swing.plaf.basic.BasicToolBarUI
All Implemented Interfaces:
SwingConstants
Direct Known Subclasses:
MetalToolBarUI

public class BasicToolBarUI
extends ToolBarUI
implements SwingConstants

A Basic L&F implementation of ToolBarUI. This implementation is a "combined" view/controller.


Inner Class Summary
 class BasicToolBarUI.DockingListener
          This inner class is marked "public" due to a compiler bug.
protected  class BasicToolBarUI.DragWindow
           
protected  class BasicToolBarUI.FrameListener
           
protected  class BasicToolBarUI.PropertyListener
           
protected  class BasicToolBarUI.ToolBarContListener
           
protected  class BasicToolBarUI.ToolBarFocusListener
           
 
Field Summary
protected  Color dockingBorderColor
           
protected  Color dockingColor
           
protected  MouseInputListener dockingListener
           
protected  KeyStroke downKey
          Deprecated. As of Java 2 platform v1.3.
protected  BasicToolBarUI.DragWindow dragWindow
           
protected  Color floatingBorderColor
           
protected  Color floatingColor
           
protected  int focusedCompIndex
           
protected  KeyStroke leftKey
          Deprecated. As of Java 2 platform v1.3.
protected  PropertyChangeListener propertyListener
           
protected  KeyStroke rightKey
          Deprecated. As of Java 2 platform v1.3.
protected  JToolBar toolBar
           
protected  ContainerListener toolBarContListener
           
protected  FocusListener toolBarFocusListener
           
protected  KeyStroke upKey
          Deprecated. As of Java 2 platform v1.3.
 
Fields inherited from interface javax.swing.SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NORTH, NORTH_EAST, NORTH_WEST, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
 
Constructor Summary
BasicToolBarUI()
           
 
Method Summary
 boolean canDock(Component c, Point p)
           
protected  MouseInputListener createDockingListener()
           
protected  BasicToolBarUI.DragWindow createDragWindow(JToolBar toolbar)
           
protected  JFrame createFloatingFrame(JToolBar toolbar)
           
protected  WindowListener createFrameListener()
           
protected  PropertyChangeListener createPropertyListener()
           
protected  ContainerListener createToolBarContListener()
           
protected  FocusListener createToolBarFocusListener()
           
static ComponentUI createUI(JComponent c)
           
protected  void dragTo(Point position, Point origin)
           
protected  void floatAt(Point position, Point origin)
           
 Color getDockingColor()
          Gets the color displayed when over a docking area
 Color getFloatingColor()
          Gets the color displayed when over a floating area
 Dimension getMaximumSize(JComponent c)
           
 Dimension getMinimumSize(JComponent c)
           
 Dimension getPreferredSize(JComponent c)
           
protected  void installComponents()
           
protected  void installDefaults()
           
protected  void installKeyboardActions()
           
protected  void installListeners()
           
 void installUI(JComponent c)
           
 boolean isFloating()
           
protected  void navigateFocusedComp(int direction)
           
 void setDockingColor(Color c)
          Sets the color displayed when over a docking area
 void setFloating(boolean b, Point p)
           
 void setFloatingColor(Color c)
          Sets the color displayed when over a floating area
 void setFloatingLocation(int x, int y)
           
 void setOrientation(int orientation)
           
protected  void uninstallComponents()
           
protected  void uninstallDefaults()
           
protected  void uninstallKeyboardActions()
           
protected  void uninstallListeners()
           
 void uninstallUI(JComponent c)
           
 
Methods inherited from class javax.swing.plaf.ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount, paint, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

toolBar

protected JToolBar toolBar

dragWindow

protected BasicToolBarUI.DragWindow dragWindow

focusedCompIndex

protected int focusedCompIndex

dockingColor

protected Color dockingColor

floatingColor

protected Color floatingColor

dockingBorderColor

protected Color dockingBorderColor

floatingBorderColor

protected Color floatingBorderColor

dockingListener

protected MouseInputListener dockingListener

propertyListener

protected PropertyChangeListener propertyListener

toolBarContListener

protected ContainerListener toolBarContListener

toolBarFocusListener

protected FocusListener toolBarFocusListener

upKey

protected KeyStroke upKey
Deprecated. As of Java 2 platform v1.3.

As of Java 2 platform v1.3 this previously undocumented field is no longer used. Key bindings are now defined by the LookAndFeel, please refer to the key bindings specification for further details.

downKey

protected KeyStroke downKey
Deprecated. As of Java 2 platform v1.3.

As of Java 2 platform v1.3 this previously undocumented field is no longer used. Key bindings are now defined by the LookAndFeel, please refer to the key bindings specification for further details.

leftKey

protected KeyStroke leftKey
Deprecated. As of Java 2 platform v1.3.

As of Java 2 platform v1.3 this previously undocumented field is no longer used. Key bindings are now defined by the LookAndFeel, please refer to the key bindings specification for further details.

rightKey

protected KeyStroke rightKey
Deprecated. As of Java 2 platform v1.3.

As of Java 2 platform v1.3 this previously undocumented field is no longer used. Key bindings are now defined by the LookAndFeel, please refer to the key bindings specification for further details.
Constructor Detail

BasicToolBarUI

public BasicToolBarUI()
Method Detail

createUI

public static ComponentUI createUI(JComponent c)

installUI

public void installUI(JComponent c)
Overrides:
installUI in class ComponentUI

uninstallUI

public void uninstallUI(JComponent c)
Overrides:
uninstallUI in class ComponentUI

installDefaults

protected void installDefaults()

uninstallDefaults

protected void uninstallDefaults()

installComponents

protected void installComponents()

uninstallComponents

protected void uninstallComponents()

installListeners

protected void installListeners()

uninstallListeners

protected void uninstallListeners()

installKeyboardActions

protected void installKeyboardActions()

uninstallKeyboardActions

protected void uninstallKeyboardActions()

navigateFocusedComp

protected void navigateFocusedComp(int direction)

createFloatingFrame

protected JFrame createFloatingFrame(JToolBar toolbar)

createDragWindow

protected BasicToolBarUI.DragWindow createDragWindow(JToolBar toolbar)

getMinimumSize

public Dimension getMinimumSize(JComponent c)
Overrides:
getMinimumSize in class ComponentUI

getPreferredSize

public Dimension getPreferredSize(JComponent c)
Overrides:
getPreferredSize in class ComponentUI

getMaximumSize

public Dimension getMaximumSize(JComponent c)
Overrides:
getMaximumSize in class ComponentUI

setFloatingLocation

public void setFloatingLocation(int x,
                                int y)

isFloating

public boolean isFloating()

setFloating

public void setFloating(boolean b,
                        Point p)

setOrientation

public void setOrientation(int orientation)

getDockingColor

public Color getDockingColor()
Gets the color displayed when over a docking area

setDockingColor

public void setDockingColor(Color c)
Sets the color displayed when over a docking area

getFloatingColor

public Color getFloatingColor()
Gets the color displayed when over a floating area

setFloatingColor

public void setFloatingColor(Color c)
Sets the color displayed when over a floating area

canDock

public boolean canDock(Component c,
                       Point p)

dragTo

protected void dragTo(Point position,
                      Point origin)

floatAt

protected void floatAt(Point position,
                       Point origin)

createToolBarContListener

protected ContainerListener createToolBarContListener()

createToolBarFocusListener

protected FocusListener createToolBarFocusListener()

createPropertyListener

protected PropertyChangeListener createPropertyListener()

createDockingListener

protected MouseInputListener createDockingListener()

createFrameListener

protected WindowListener createFrameListener()

JavaTM 2 Platform
Std. Ed. v1.3.1

Submit a bug or feature
For further API reference and developer documentation, see Java 2 SDK SE Developer Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.

Java, Java 2D, and JDBC are trademarks or registered trademarks of Oracle and/or its affiliates, in the US and other countries.
Copyright © 1995, 2010 Oracle and/or its affiliates. All rights reserved.