pivot.wtk.skin.terra
Class TerraSplitPaneSkin

java.lang.Object
  extended by pivot.wtk.skin.ComponentSkin
      extended by pivot.wtk.skin.ContainerSkin
          extended by pivot.wtk.skin.terra.TerraSplitPaneSkin
All Implemented Interfaces:
ComponentKeyListener, ComponentLayoutListener, ComponentListener, ComponentMouseButtonListener, ComponentMouseListener, ComponentMouseWheelListener, ComponentStateListener, ConstrainedVisual, ContainerListener, Skin, SplitPaneListener, Visual

public class TerraSplitPaneSkin
extends ContainerSkin
implements SplitPaneListener

Split pane skin.

Author:
tvolkert

Nested Class Summary
protected  class TerraSplitPaneSkin.Splitter
          Split pane splitter component.
protected  class TerraSplitPaneSkin.SplitterShadow
          Split pane splitter shadow component.
protected  class TerraSplitPaneSkin.SplitterShadowSkin
          Split pane splitter shadow component skin.
protected  class TerraSplitPaneSkin.SplitterSkin
          Split pane splitter component skin.
 
Nested classes/interfaces inherited from class pivot.wtk.skin.ContainerSkin
ContainerSkin.IndexFocusTraversalPolicy
 
Field Summary
 
Fields inherited from class pivot.wtk.skin.ComponentSkin
SHOW_TOOLTIP_TIMEOUT
 
Constructor Summary
TerraSplitPaneSkin()
           
 
Method Summary
 void bottomRightComponentChanged(SplitPane splitPane, Component previousBottomRightComponent)
          Called when a split pane's bottom right component has changed.
 int getPreferredHeight(int width)
          Returns the visual's preferred height given the provided width constraint.
 Dimensions getPreferredSize()
          Returns the visual's unconstrained preferred size.
 int getPreferredWidth(int height)
          Returns the visual's preferred width given the provided height constraint.
 java.awt.Color getSplitterHandlePrimaryColor()
           
 java.awt.Color getSplitterHandleSecondaryColor()
           
 int getSplitterThickness()
           
 boolean getUseShadow()
           
 void install(Component component)
          Associates a skin with a component.
 void layout()
          If the component on which the skin is installed is a container, lays out the container's children.
 void lockedChanged(SplitPane splitPane)
          Called when a split pane's locked flag has changed.
 void orientationChanged(SplitPane splitPane)
          Called when a split pane's orientation has changed.
 void primaryRegionChanged(SplitPane splitPane)
          Called when a split pane's primary region has changed.
 void setSplitterHandlePrimaryColor(java.awt.Color splitterHandlePrimaryColor)
           
 void setSplitterHandlePrimaryColor(int splitterHandlePrimaryColor)
           
 void setSplitterHandlePrimaryColor(java.lang.String splitterHandlePrimaryColor)
           
 void setSplitterHandleSecondaryColor(java.awt.Color splitterHandleSecondaryColor)
           
 void setSplitterHandleSecondaryColor(int splitterHandleSecondaryColor)
           
 void setSplitterHandleSecondaryColor(java.lang.String splitterHandleSecondaryColor)
           
 void setSplitterThickness(int splitterThickness)
           
 void setUseShadow(boolean useShadow)
           
 void splitBoundsChanged(SplitPane splitPane, Span previousSplitBounds)
          Called when a split pane's split bounds have changed.
 void splitLocationChanged(SplitPane splitPane, int previousSplitLocation)
          Called when a split pane's split location has changed.
 void topLeftComponentChanged(SplitPane splitPane, Component previousTopLeftComponent)
          Called when a split pane's top left component has changed.
 void uninstall()
          Dissociates a skin from a component.
 
Methods inherited from class pivot.wtk.skin.ContainerSkin
componentInserted, componentsRemoved, contextKeyChanged, focusTraversalPolicyChanged, getBackgroundColor, getBackgroundPaint, isFocusable, paint, setBackgroundColor, setBackgroundColor, setBackgroundPaint
 
Methods inherited from class pivot.wtk.skin.ComponentSkin
cursorChanged, decodeColor, displayableChanged, enabledChanged, focusedChanged, getComponent, getHeight, getWidth, invalidateComponent, keyPressed, keyReleased, keyTyped, locationChanged, mouseClick, mouseDown, mouseMove, mouseOut, mouseOver, mouseUp, mouseWheel, parentChanged, preferredSizeChanged, repaintComponent, repaintComponent, repaintComponent, setSize, sizeChanged, styleUpdated, tooltipTextChanged, visibleChanged
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TerraSplitPaneSkin

public TerraSplitPaneSkin()
Method Detail

install

public void install(Component component)
Description copied from interface: Skin
Associates a skin with a component.

Specified by:
install in interface Skin
Overrides:
install in class ContainerSkin
Parameters:
component - The component to which the skin is being attached.

uninstall

public void uninstall()
Description copied from interface: Skin
Dissociates a skin from a component.

Specified by:
uninstall in interface Skin
Overrides:
uninstall in class ContainerSkin

getPreferredWidth

public int getPreferredWidth(int height)
Description copied from interface: ConstrainedVisual
Returns the visual's preferred width given the provided height constraint.

Specified by:
getPreferredWidth in interface ConstrainedVisual
Overrides:
getPreferredWidth in class ContainerSkin
Parameters:
height - The height by which to constrain the preferred width, or -1 for no constraint.

getPreferredHeight

public int getPreferredHeight(int width)
Description copied from interface: ConstrainedVisual
Returns the visual's preferred height given the provided width constraint.

Specified by:
getPreferredHeight in interface ConstrainedVisual
Overrides:
getPreferredHeight in class ContainerSkin
Parameters:
width - The width by which to constrain the preferred height, or -1 for no constraint.

getPreferredSize

public Dimensions getPreferredSize()
Description copied from interface: ConstrainedVisual
Returns the visual's unconstrained preferred size.

Specified by:
getPreferredSize in interface ConstrainedVisual
Overrides:
getPreferredSize in class ComponentSkin

layout

public void layout()
Description copied from interface: Skin
If the component on which the skin is installed is a container, lays out the container's children.

Specified by:
layout in interface Skin

getSplitterHandlePrimaryColor

public java.awt.Color getSplitterHandlePrimaryColor()

setSplitterHandlePrimaryColor

public void setSplitterHandlePrimaryColor(java.awt.Color splitterHandlePrimaryColor)

setSplitterHandlePrimaryColor

public final void setSplitterHandlePrimaryColor(java.lang.String splitterHandlePrimaryColor)

setSplitterHandlePrimaryColor

public final void setSplitterHandlePrimaryColor(int splitterHandlePrimaryColor)

getSplitterHandleSecondaryColor

public java.awt.Color getSplitterHandleSecondaryColor()

setSplitterHandleSecondaryColor

public void setSplitterHandleSecondaryColor(java.awt.Color splitterHandleSecondaryColor)

setSplitterHandleSecondaryColor

public final void setSplitterHandleSecondaryColor(java.lang.String splitterHandleSecondaryColor)

setSplitterHandleSecondaryColor

public final void setSplitterHandleSecondaryColor(int splitterHandleSecondaryColor)

getSplitterThickness

public int getSplitterThickness()

setSplitterThickness

public void setSplitterThickness(int splitterThickness)

getUseShadow

public boolean getUseShadow()

setUseShadow

public void setUseShadow(boolean useShadow)

topLeftComponentChanged

public void topLeftComponentChanged(SplitPane splitPane,
                                    Component previousTopLeftComponent)
Description copied from interface: SplitPaneListener
Called when a split pane's top left component has changed.

Specified by:
topLeftComponentChanged in interface SplitPaneListener

bottomRightComponentChanged

public void bottomRightComponentChanged(SplitPane splitPane,
                                        Component previousBottomRightComponent)
Description copied from interface: SplitPaneListener
Called when a split pane's bottom right component has changed.

Specified by:
bottomRightComponentChanged in interface SplitPaneListener

orientationChanged

public void orientationChanged(SplitPane splitPane)
Description copied from interface: SplitPaneListener
Called when a split pane's orientation has changed.

Specified by:
orientationChanged in interface SplitPaneListener

primaryRegionChanged

public void primaryRegionChanged(SplitPane splitPane)
Description copied from interface: SplitPaneListener
Called when a split pane's primary region has changed.

Specified by:
primaryRegionChanged in interface SplitPaneListener

splitLocationChanged

public void splitLocationChanged(SplitPane splitPane,
                                 int previousSplitLocation)
Description copied from interface: SplitPaneListener
Called when a split pane's split location has changed.

Specified by:
splitLocationChanged in interface SplitPaneListener

splitBoundsChanged

public void splitBoundsChanged(SplitPane splitPane,
                               Span previousSplitBounds)
Description copied from interface: SplitPaneListener
Called when a split pane's split bounds have changed.

Specified by:
splitBoundsChanged in interface SplitPaneListener

lockedChanged

public void lockedChanged(SplitPane splitPane)
Description copied from interface: SplitPaneListener
Called when a split pane's locked flag has changed.

Specified by:
lockedChanged in interface SplitPaneListener