|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.pivot.wtk.skin.ComponentSkin
org.apache.pivot.wtk.skin.ContainerSkin
org.apache.pivot.wtk.skin.ScrollPaneSkin
public class ScrollPaneSkin
Scroll pane skin.
Nested Class Summary |
---|
Nested classes/interfaces inherited from class org.apache.pivot.wtk.skin.ContainerSkin |
---|
ContainerSkin.IndexFocusTraversalPolicy |
Nested classes/interfaces inherited from interface org.apache.pivot.wtk.ScrollPaneListener |
---|
ScrollPaneListener.Adapter |
Nested classes/interfaces inherited from interface org.apache.pivot.wtk.ViewportListener |
---|
ViewportListener.Adapter |
Nested classes/interfaces inherited from interface org.apache.pivot.wtk.ContainerListener |
---|
ContainerListener.Adapter |
Nested classes/interfaces inherited from interface org.apache.pivot.wtk.ContainerMouseListener |
---|
ContainerMouseListener.Adapter |
Nested classes/interfaces inherited from interface org.apache.pivot.wtk.ComponentListener |
---|
ComponentListener.Adapter |
Nested classes/interfaces inherited from interface org.apache.pivot.wtk.ComponentStateListener |
---|
ComponentStateListener.Adapter |
Nested classes/interfaces inherited from interface org.apache.pivot.wtk.ComponentMouseListener |
---|
ComponentMouseListener.Adapter |
Nested classes/interfaces inherited from interface org.apache.pivot.wtk.ComponentMouseButtonListener |
---|
ComponentMouseButtonListener.Adapter |
Nested classes/interfaces inherited from interface org.apache.pivot.wtk.ComponentKeyListener |
---|
ComponentKeyListener.Adapter |
Constructor Summary | |
---|---|
ScrollPaneSkin()
|
Method Summary | |
---|---|
void |
columnHeaderChanged(ScrollPane scrollPane,
Component previousColumnHeader)
Called when the scroll pane's column header changed. |
void |
cornerChanged(ScrollPane scrollPane,
Component previousCorner)
Called when the scroll pane's corner component changed. |
int |
getBaseline(int width,
int height)
Returns the baseline for a given width and height. |
int |
getHorizontalIncrement()
|
int |
getHorizontalReveal()
|
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. |
int |
getVerticalIncrement()
|
int |
getVerticalReveal()
|
Bounds |
getViewportBounds()
The bounds of the Viewport within the container, for example, in ScrollPaneSkin, this excludes the scrollbars. |
void |
horizontalScrollBarPolicyChanged(ScrollPane scrollPane,
ScrollPane.ScrollBarPolicy previousHorizontalScrollBarPolicy)
Called when the scroll pane's horizontal scroll bar policy changed. |
void |
install(Component component)
Associates a skin with a component. |
boolean |
keyPressed(Component component,
int keyCode,
Keyboard.KeyLocation keyLocation)
Key presses have no effect if the event has already been consumed. |
void |
layout()
If the component on which the skin is installed is a container, lays out the container's children. |
boolean |
mouseWheel(Component component,
Mouse.ScrollType scrollType,
int scrollAmount,
int wheelRotation,
int x,
int y)
Called when the mouse wheel is scrolled over a component. |
void |
rowHeaderChanged(ScrollPane scrollPane,
Component previousRowHeader)
Called when the scroll pane's row header changed. |
void |
scrollLeftChanged(Viewport viewport,
int previousScrollLeft)
Called when a viewport's scroll left has changed. |
void |
scrollTopChanged(Viewport viewport,
int previousScrollTop)
Called when a viewport's scroll top has changed. |
void |
setBackgroundPaint(Paint backgroundPaint)
Sets the object used to paint the background of the container. |
void |
setHorizontalIncrement(int horizontalIncrement)
|
void |
setHorizontalReveal(int horizontalReveal)
|
void |
setVerticalIncrement(int verticalIncrement)
|
void |
setVerticalReveal(int verticalReveal)
|
void |
valueChanged(ScrollBar scrollBar,
int previousValue)
Called when a scroll bar's value has changed. |
void |
verticalScrollBarPolicyChanged(ScrollPane scrollPane,
ScrollPane.ScrollBarPolicy previousVerticalScrollBarPolicy)
Called when the scroll pane's vertical scroll bar policy changed. |
void |
viewChanged(Viewport viewport,
Component previousView)
Called when a viewport's view component has changed. |
Methods inherited from class org.apache.pivot.wtk.skin.ContainerSkin |
---|
componentInserted, componentMoved, componentsRemoved, focusTraversalPolicyChanged, getBackgroundColor, getBackgroundPaint, isFocusable, isOpaque, mouseDown, mouseMove, mouseUp, mouseWheel, paint, setBackgroundColor, setBackgroundColor, setBackgroundPaint, setBackgroundPaint |
Methods inherited from class org.apache.pivot.wtk.skin.ComponentSkin |
---|
cursorChanged, decodeFont, dragSourceChanged, dropTargetChanged, enabledChanged, focusedChanged, getBaseline, getComponent, getHeight, getWidth, heightLimitsChanged, invalidateComponent, keyReleased, keyTyped, locationChanged, menuHandlerChanged, mouseClick, mouseDown, mouseMove, mouseOut, mouseOver, mouseUp, nameChanged, parentChanged, preferredSizeChanged, repaintComponent, repaintComponent, repaintComponent, repaintComponent, repaintComponent, setSize, sizeChanged, tooltipDelayChanged, tooltipTextChanged, tooltipTriggered, visibleChanged, widthLimitsChanged |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ScrollPaneSkin()
Method Detail |
---|
public void install(Component component)
Skin
install
in interface Skin
install
in class ContainerSkin
component
- The component to which the skin is being attached.public int getPreferredWidth(int height)
ConstrainedVisual
getPreferredWidth
in interface ConstrainedVisual
getPreferredWidth
in class ContainerSkin
height
- The height by which to constrain the preferred width, or -1
for no constraint.public int getPreferredHeight(int width)
ConstrainedVisual
getPreferredHeight
in interface ConstrainedVisual
getPreferredHeight
in class ContainerSkin
width
- The width by which to constrain the preferred height, or -1
for no constraint.public Dimensions getPreferredSize()
ConstrainedVisual
getPreferredSize
in interface ConstrainedVisual
getPreferredSize
in class ComponentSkin
public int getBaseline(int width, int height)
ConstrainedVisual
getBaseline
in interface ConstrainedVisual
getBaseline
in class ComponentSkin
public boolean mouseWheel(Component component, Mouse.ScrollType scrollType, int scrollAmount, int wheelRotation, int x, int y)
ComponentMouseWheelListener
mouseWheel
in interface ComponentMouseWheelListener
mouseWheel
in class ComponentSkin
public boolean keyPressed(Component component, int keyCode, Keyboard.KeyLocation keyLocation)
UP
Scroll up a single scroll unit.
DOWN
Scroll down a single scroll unit.
LEFT
Scroll left a single scroll unit.
RIGHT
Scroll right a single scroll unit.
PAGE_UP
Scroll up a single scroll block.
PAGE_DOWN
Scroll down a single scroll block.
keyPressed
in interface ComponentKeyListener
keyPressed
in class ComponentSkin
ScrollBar.getBlockIncrement()
,
ScrollBar.getUnitIncrement()
public void layout()
Skin
layout
in interface Skin
public void setBackgroundPaint(Paint backgroundPaint)
ContainerSkin
setBackgroundPaint
in class ContainerSkin
backgroundPaint
- The Paint
objectpublic int getHorizontalIncrement()
public void setHorizontalIncrement(int horizontalIncrement)
public int getVerticalIncrement()
public void setVerticalIncrement(int verticalIncrement)
public int getHorizontalReveal()
public void setHorizontalReveal(int horizontalReveal)
public int getVerticalReveal()
public void setVerticalReveal(int verticalReveal)
public Bounds getViewportBounds()
Viewport.Skin
getViewportBounds
in interface Viewport.Skin
public void horizontalScrollBarPolicyChanged(ScrollPane scrollPane, ScrollPane.ScrollBarPolicy previousHorizontalScrollBarPolicy)
ScrollPaneListener
horizontalScrollBarPolicyChanged
in interface ScrollPaneListener
public void verticalScrollBarPolicyChanged(ScrollPane scrollPane, ScrollPane.ScrollBarPolicy previousVerticalScrollBarPolicy)
ScrollPaneListener
verticalScrollBarPolicyChanged
in interface ScrollPaneListener
public void rowHeaderChanged(ScrollPane scrollPane, Component previousRowHeader)
ScrollPaneListener
rowHeaderChanged
in interface ScrollPaneListener
public void columnHeaderChanged(ScrollPane scrollPane, Component previousColumnHeader)
ScrollPaneListener
columnHeaderChanged
in interface ScrollPaneListener
public void cornerChanged(ScrollPane scrollPane, Component previousCorner)
ScrollPaneListener
cornerChanged
in interface ScrollPaneListener
public void scrollTopChanged(Viewport viewport, int previousScrollTop)
ViewportListener
scrollTopChanged
in interface ViewportListener
public void scrollLeftChanged(Viewport viewport, int previousScrollLeft)
ViewportListener
scrollLeftChanged
in interface ViewportListener
public void viewChanged(Viewport viewport, Component previousView)
ViewportListener
viewChanged
in interface ViewportListener
public void valueChanged(ScrollBar scrollBar, int previousValue)
ScrollBarValueListener
valueChanged
in interface ScrollBarValueListener
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |