Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Swing 1.1
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## javax.swing.plaf.basic
Class BasicSplitPaneUI

    java.lang.Object
      |
      +--javax.swing.plaf.ComponentUI
            |
            +--javax.swing.plaf.SplitPaneUI
                  |
                  +--javax.swing.plaf.basic.BasicSplitPaneUI

Direct Known Subclasses:
  MetalSplitPaneUI

public class BasicSplitPaneUI
extends SplitPaneUI

A Basic L&F implementation of the SplitPaneUI.

Inner Class Summary
`class` | `BasicSplitPaneUI.BasicHorizontalLayoutManager` LayoutManager for JSplitPanes that have an orientation of HORIZONTAL_SPLIT.
`class` | `BasicSplitPaneUI.BasicVerticalLayoutManager` LayoutManager used for JSplitPanes with an orientation of VERTICAL_SPLIT.
`class` | `BasicSplitPaneUI.FocusHandler` Implementation of the FocusListener that the JSplitPane UI uses.
`class` | `BasicSplitPaneUI.KeyboardDownRightHandler` Implementation of an ActionListener that the JSplitPane UI uses for handling specific key presses.
`class` | `BasicSplitPaneUI.KeyboardEndHandler` Implementation of an ActionListener that the JSplitPane UI uses for handling specific key presses.
`class` | `BasicSplitPaneUI.KeyboardHomeHandler` Implementation of an ActionListener that the JSplitPane UI uses for handling specific key presses.
`class` | `BasicSplitPaneUI.KeyboardResizeToggleHandler` Implementation of an ActionListener that the JSplitPane UI uses for handling specific key presses.
`class` | `BasicSplitPaneUI.KeyboardUpLeftHandler` Implementation of an ActionListener that the JSplitPane UI uses for handling specific key presses.
`class` | `BasicSplitPaneUI.PropertyHandler` Implementation of the PropertyChangeListener that the JSplitPane UI uses.

Field Summary
`protected int` | `beginDragDividerLocation` Location of the divider when the dragging session began.
`protected BasicSplitPaneDivider` | `divider` Instance of the divider for this JSplitPane.
`protected KeyStroke` | `dividerResizeToggleKey`
`protected int` | `dividerSize` The size of the divider while the dragging session is valid.
`protected KeyStroke` | `downKey`
`protected boolean` | `draggingHW` Set to true in startDragging if any of the children (not including the nonContinuousLayoutDivider) are heavy weights.
`protected KeyStroke` | `endKey`
`protected java.awt.event.FocusListener` | `focusListener` Instance of the FocusListener for this JSplitPane.
`protected KeyStroke` | `homeKey`
`protected static int` | `KEYBOARD_DIVIDER_MOVE_OFFSET` How far (relativ) the divider does move when it is moved around by the cursor keys on the keyboard.
`protected java.awt.event.ActionListener` | `keyboardDownRightListener`
`protected java.awt.event.ActionListener` | `keyboardEndListener`
`protected java.awt.event.ActionListener` | `keyboardHomeListener`
`protected java.awt.event.ActionListener` | `keyboardResizeToggleListener`
`protected java.awt.event.ActionListener` | `keyboardUpLeftListener` The handlers that are handling the keystrokes for keyboard navigation.
`protected BasicSplitPaneUI.BasicHorizontalLayoutManager` | `layoutManager` LayoutManager that is created and placed into the split pane.
`protected KeyStroke` | `leftKey`
`protected static java.lang.String` | `NON_CONTINUOUS_DIVIDER` The divider used for non-continuous layout is added to the split pane with this object.
`protected java.awt.Component` | `nonContinuousLayoutDivider` Instance for the shadow of the divider when non continuous layout is being used.
`protected java.beans.PropertyChangeListener` | `propertyChangeListener` Instance of the PropertyChangeListener for this JSplitPane.
`protected KeyStroke` | `rightKey`
`protected JSplitPane` | `splitPane` JSplitPane instance this instance is providing the look and feel for.
`protected KeyStroke` | `upKey` The keystrokes that the JSplitPane is supposed to handle.

Constructor Summary
`BasicSplitPaneUI()`

Method Summary
`BasicSplitPaneDivider` | `createDefaultDivider()` Creates the default divider.
`protected java.awt.Component` | `createDefaultNonContinuousLayoutDivider()` Returns the default non continuous layout divider, which is an instanceof Canvas that fills the background in dark gray.
`protected java.awt.event.FocusListener` | `createFocusListener()` Creates a FocusListener for the JSplitPane UI.
`protected java.awt.event.ActionListener` | `createKeyboardDownRightListener()` Creates a ActionListener for the JSplitPane UI that listens for specific key presses.
`protected java.awt.event.ActionListener` | `createKeyboardEndListener()` Creates a ActionListener for the JSplitPane UI that listens for specific key presses.
`protected java.awt.event.ActionListener` | `createKeyboardHomeListener()` Creates a ActionListener for the JSplitPane UI that listens for specific key presses.
`protected java.awt.event.ActionListener` | `createKeyboardResizeToggleListener()` Creates a ActionListener for the JSplitPane UI that listens for specific key presses.
`protected java.awt.event.ActionListener` | `createKeyboardUpLeftListener()` Creates a ActionListener for the JSplitPane UI that listens for specific key presses.
`protected java.beans.PropertyChangeListener` | `createPropertyChangeListener()` Creates a PropertyChangeListener for the JSplitPane UI.
`static ComponentUI` | `createUI(JComponent x)` Creates a new BasicSplitPaneUI instance
`protected void` | `dragDividerTo(int location)` Messaged during a dragging session to move the divider to the passed in location.
`protected void` | `finishDraggingTo(int location)` Messaged to finish the dragging session.
`void` | `finishedPaintingChildren(JSplitPane jc, java.awt.Graphics g)` Messaged after the JSplitPane the receiver is providing the look and feel for paints its children.
`BasicSplitPaneDivider` | `getDivider()` Returns the divider between the top Components.
`protected int` | `getDividerBorderSize()` Returns the width of one side of the divider border.
`int` | `getDividerLocation(JSplitPane jc)` Returns the location of the divider.
`java.awt.Insets` | `getInsets(JComponent jc)` Returns the insets.
`int` | `getLastDragLocation()` Returns the last drag location of the JSplitPane.
`int` | `getMaximumDividerLocation(JSplitPane jc)` Gets the maximum location of the divider.
`java.awt.Dimension` | `getMaximumSize(JComponent jc)` Returns the maximum size for the passed in component, This is passed off to the current layoutmanager.
`int` | `getMinimumDividerLocation(JSplitPane jc)` Gets the minimum location of the divider.
`java.awt.Dimension` | `getMinimumSize(JComponent jc)` Returns the minimum size for the passed in component, This is passed off to the current layoutmanager.
`java.awt.Component` | `getNonContinuousLayoutDivider()` Returns the divider to use when the splitPane is configured to not continuously layout.
`int` | `getOrientation()` Returns the orientation for the JSplitPane.
`java.awt.Dimension` | `getPreferredSize(JComponent jc)` Returns the preferred size for the passed in component, This is passed off to the current layoutmanager.
`JSplitPane` | `getSplitPane()` Returns the splitpane this instance is currently contained in.
`protected void` | `installDefaults()` Installs the UI defaults.
`protected void` | `installKeyboardActions()` Installs the keyboard actions for the UI.
`protected void` | `installListeners()` Installs the event listeners for the UI.
`void` | `installUI(JComponent c)` Installs the UI.
`boolean` | `isContinuousLayout()` Determines wether the JSplitPane is set to use a continuous layout.
`void` | `paint(java.awt.Graphics g, JComponent jc)` Messaged to paint the look and feel.
`protected void` | `resetLayoutManager()` Resets the layout manager based on orientation and messages it with invalidateLayout to pull in appropriate Components.
`void` | `resetToPreferredSizes(JSplitPane jc)` Messaged to reset the preferred sizes.
`void` | `setContinuousLayout(boolean b)` Turn continuous layout on/off.
`void` | `setDividerLocation(JSplitPane jc, int location)` Sets the location of the divider to location.
`void` | `setLastDragLocation(int l)` Set the last drag location of the JSplitPane.
`protected void` | `setNonContinuousLayoutDivider(java.awt.Component newDivider)` Sets the divider to use when the splitPane is configured to not continuously layout.
`protected void` | `setNonContinuousLayoutDivider(java.awt.Component newDivider, boolean rememberSizes)` Sets the divider to use.
`void` | `setOrientation(int orientation)` Set the orientation for the JSplitPane.
`protected void` | `startDragging()` Should be messaged before the dragging session starts, resets lastDragLocation and dividerSize.
`protected void` | `uninstallDefaults()` Uninstalls the UI defaults.
`protected void` | `uninstallKeyboardActions()` Uninstalls the keyboard actions for the UI.
`protected void` | `uninstallListeners()` Uninstalls the event listeners for the UI.
`void` | `uninstallUI(JComponent c)` Uninstalls the UI.

Methods inherited from class javax.swing.plaf.ComponentUI
`contains, getAccessibleChild, getAccessibleChildrenCount, update`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### NON_CONTINUOUS_DIVIDER

    protected static final java.lang.String NON_CONTINUOUS_DIVIDER

  The divider used for non-continuous layout is added to the split pane with this object.

### KEYBOARD_DIVIDER_MOVE_OFFSET

    protected static int KEYBOARD_DIVIDER_MOVE_OFFSET

  How far (relativ) the divider does move when it is moved around by the cursor keys on the keyboard.

### splitPane

    protected JSplitPane splitPane

  JSplitPane instance this instance is providing the look and feel for.

### layoutManager

    protected BasicSplitPaneUI.BasicHorizontalLayoutManager layoutManager

  LayoutManager that is created and placed into the split pane.

### divider

    protected BasicSplitPaneDivider divider

  Instance of the divider for this JSplitPane.

### propertyChangeListener

    protected java.beans.PropertyChangeListener propertyChangeListener

  Instance of the PropertyChangeListener for this JSplitPane.

### focusListener

    protected java.awt.event.FocusListener focusListener

  Instance of the FocusListener for this JSplitPane.

### dividerSize

    protected int dividerSize

  The size of the divider while the dragging session is valid.

### nonContinuousLayoutDivider

    protected java.awt.Component nonContinuousLayoutDivider

  Instance for the shadow of the divider when non continuous layout is being used.

### draggingHW

    protected boolean draggingHW

  Set to true in startDragging if any of the children (not including the nonContinuousLayoutDivider) are heavy weights.

### beginDragDividerLocation

    protected int beginDragDividerLocation

  Location of the divider when the dragging session began.

### upKey

    protected KeyStroke upKey

  The keystrokes that the JSplitPane is supposed to handle.

### downKey

    protected KeyStroke downKey

### leftKey

    protected KeyStroke leftKey

### rightKey

    protected KeyStroke rightKey

### homeKey

    protected KeyStroke homeKey

### endKey

    protected KeyStroke endKey

### dividerResizeToggleKey

    protected KeyStroke dividerResizeToggleKey

### keyboardUpLeftListener

    protected java.awt.event.ActionListener keyboardUpLeftListener

  The handlers that are handling the keystrokes for keyboard navigation.

### keyboardDownRightListener

    protected java.awt.event.ActionListener keyboardDownRightListener

### keyboardHomeListener

    protected java.awt.event.ActionListener keyboardHomeListener

### keyboardEndListener

    protected java.awt.event.ActionListener keyboardEndListener

### keyboardResizeToggleListener

    protected java.awt.event.ActionListener keyboardResizeToggleListener

Constructor Detail

### BasicSplitPaneUI

    public BasicSplitPaneUI()

Method Detail

### createUI

    public static ComponentUI createUI(JComponent x)

  Creates a new BasicSplitPaneUI instance

### installUI

    public void installUI(JComponent c)

  Installs the UI.
  Overrides:
    installUI in class ComponentUI

### installDefaults

    protected void installDefaults()

  Installs the UI defaults.

### installListeners

    protected void installListeners()

  Installs the event listeners for the UI.

### installKeyboardActions

    protected void installKeyboardActions()

  Installs the keyboard actions for the UI.

### uninstallUI

    public void uninstallUI(JComponent c)

  Uninstalls the UI.
  Overrides:
    uninstallUI in class ComponentUI

### uninstallDefaults

    protected void uninstallDefaults()

  Uninstalls the UI defaults.

### uninstallListeners

    protected void uninstallListeners()

  Uninstalls the event listeners for the UI.

### uninstallKeyboardActions

    protected void uninstallKeyboardActions()

  Uninstalls the keyboard actions for the UI.

### createPropertyChangeListener

    protected java.beans.PropertyChangeListener createPropertyChangeListener()

  Creates a PropertyChangeListener for the JSplitPane UI.

### createFocusListener

    protected java.awt.event.FocusListener createFocusListener()

  Creates a FocusListener for the JSplitPane UI.

### createKeyboardUpLeftListener

    protected java.awt.event.ActionListener createKeyboardUpLeftListener()

  Creates a ActionListener for the JSplitPane UI that listens for specific key presses.

### createKeyboardDownRightListener

    protected java.awt.event.ActionListener createKeyboardDownRightListener()

  Creates a ActionListener for the JSplitPane UI that listens for specific key presses.

### createKeyboardHomeListener

    protected java.awt.event.ActionListener createKeyboardHomeListener()

  Creates a ActionListener for the JSplitPane UI that listens for specific key presses.

### createKeyboardEndListener

    protected java.awt.event.ActionListener createKeyboardEndListener()

  Creates a ActionListener for the JSplitPane UI that listens for specific key presses.

### createKeyboardResizeToggleListener

    protected java.awt.event.ActionListener createKeyboardResizeToggleListener()

  Creates a ActionListener for the JSplitPane UI that listens for specific key presses.

### getOrientation

    public int getOrientation()

  Returns the orientation for the JSplitPane.

### setOrientation

    public void setOrientation(int orientation)

  Set the orientation for the JSplitPane.

### isContinuousLayout

    public boolean isContinuousLayout()

  Determines wether the JSplitPane is set to use a continuous layout.

### setContinuousLayout

    public void setContinuousLayout(boolean b)

  Turn continuous layout on/off.

### getLastDragLocation

    public int getLastDragLocation()

  Returns the last drag location of the JSplitPane.

### setLastDragLocation

    public void setLastDragLocation(int l)

  Set the last drag location of the JSplitPane.

### getDivider

    public BasicSplitPaneDivider getDivider()

  Returns the divider between the top Components.

### createDefaultNonContinuousLayoutDivider

    protected java.awt.Component createDefaultNonContinuousLayoutDivider()

  Returns the default non continuous layout divider, which is an instanceof Canvas that fills the background in dark gray.

### setNonContinuousLayoutDivider

    protected void setNonContinuousLayoutDivider(java.awt.Component newDivider)

  Sets the divider to use when the splitPane is configured to not continuously layout. This divider will only be used during a dragging session. It is recommended that the passed in component be a heavy weight.

### setNonContinuousLayoutDivider

    protected void setNonContinuousLayoutDivider(java.awt.Component newDivider,
                                                 boolean rememberSizes)

  Sets the divider to use.

### getNonContinuousLayoutDivider

    public java.awt.Component getNonContinuousLayoutDivider()

  Returns the divider to use when the splitPane is configured to not continuously layout. This divider will only be used during a dragging session.

### getSplitPane

    public JSplitPane getSplitPane()

  Returns the splitpane this instance is currently contained in.

### createDefaultDivider

    public BasicSplitPaneDivider createDefaultDivider()

  Creates the default divider.

### resetToPreferredSizes

    public void resetToPreferredSizes(JSplitPane jc)

  Messaged to reset the preferred sizes.
  Overrides:
    resetToPreferredSizes in class SplitPaneUI

### setDividerLocation

    public void setDividerLocation(JSplitPane jc,
                                   int location)

  Sets the location of the divider to location.
  Overrides:
    setDividerLocation in class SplitPaneUI

### getDividerLocation

    public int getDividerLocation(JSplitPane jc)

  Returns the location of the divider.
  Overrides:
    getDividerLocation in class SplitPaneUI

### getMinimumDividerLocation

    public int getMinimumDividerLocation(JSplitPane jc)

  Gets the minimum location of the divider.
  Overrides:
    getMinimumDividerLocation in class SplitPaneUI

### getMaximumDividerLocation

    public int getMaximumDividerLocation(JSplitPane jc)

  Gets the maximum location of the divider.
  Overrides:
    getMaximumDividerLocation in class SplitPaneUI

### finishedPaintingChildren

    public void finishedPaintingChildren(JSplitPane jc,
                                         java.awt.Graphics g)

  Messaged after the JSplitPane the receiver is providing the look and feel for paints its children.
  Overrides:
    finishedPaintingChildren in class SplitPaneUI

### paint

    public void paint(java.awt.Graphics g,
                      JComponent jc)

  Messaged to paint the look and feel.
  Overrides:
    paint in class ComponentUI

### getPreferredSize

    public java.awt.Dimension getPreferredSize(JComponent jc)

  Returns the preferred size for the passed in component, This is passed off to the current layoutmanager.
  Overrides:
    getPreferredSize in class ComponentUI

### getMinimumSize

    public java.awt.Dimension getMinimumSize(JComponent jc)

  Returns the minimum size for the passed in component, This is passed off to the current layoutmanager.
  Overrides:
    getMinimumSize in class ComponentUI

### getMaximumSize

    public java.awt.Dimension getMaximumSize(JComponent jc)

  Returns the maximum size for the passed in component, This is passed off to the current layoutmanager.
  Overrides:
    getMaximumSize in class ComponentUI

### getInsets

    public java.awt.Insets getInsets(JComponent jc)

  Returns the insets. The insets are returned from the broder insets of the current border.

### resetLayoutManager

    protected void resetLayoutManager()

  Resets the layout manager based on orientation and messages it with invalidateLayout to pull in appropriate Components.

### startDragging

    protected void startDragging()

  Should be messaged before the dragging session starts, resets lastDragLocation and dividerSize.

### dragDividerTo

    protected void dragDividerTo(int location)

  Messaged during a dragging session to move the divider to the passed in location. If continuousLayout is true the location is reset and the splitPane validated.

### finishDraggingTo

    protected void finishDraggingTo(int location)

  Messaged to finish the dragging session. If not continuous display the dividers location will be reset.

### getDividerBorderSize

    protected int getDividerBorderSize()

  Returns the width of one side of the divider border.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Swing 1.1
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Submit a bug or feature
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.
Copyright 1993-1998 Sun Microsystems, Inc. 901 San Antonio Road,
Palo Alto, California, 94303, U.S.A. All Rights Reserved.