APIdia Launch Partner
Top Description Methods
java.awt.peer

public Interface ScrollPanePeer

extends ContainerPeer
Known Direct Implementers
sun.awt.X11.XScrollPanePeer
Imports
java.awt.Adjustable, .ScrollPane, .ScrollPaneAdjustable

The peer interface for ScrollPane. The peer interfaces are intended only for use in porting the AWT. They are not intended for use by application developers, and developers should not implement peers nor invoke any of the peer methods directly on the peer instances.

Method Summary

Modifier and TypeMethod and Description
public void
childResized(int
the new width of the child component
w
,
int
the new height of the child component
h
)

Called when the child component changes its size.

public int

Returns:

the height of the horizontal scroll bar
getHScrollbarHeight
()

Returns the height of the horizontal scroll bar.

public int

Returns:

the width of the vertical scroll bar
getVScrollbarWidth
()

Returns the width of the vertical scroll bar.

public void
setScrollPosition(int
the X coordinate of the scroll position
x
,
int
the Y coordinate of the scroll position
y
)

Sets the scroll position of the child.

public void
setUnitIncrement(Adjustable
the scroll pane adjustable object
adj
,
int
the unit increment
u
)

Sets the unit increment of one of the scroll pane's adjustables.

public void
setValue(Adjustable
the scroll pane adjustable object
adj
,
int
the value to set
v
)

Sets the value for one of the scroll pane's adjustables.

Inherited from java.awt.peer.ContainerPeer:
beginLayoutbeginValidateendLayoutendValidategetInsets

Method Detail

childResizedback to summary
public void childResized(int w, int h)

Called when the child component changes its size.

Parameters
w:int

the new width of the child component

h:int

the new height of the child component

See Also
ScrollPane#layout()
getHScrollbarHeightback to summary
public int getHScrollbarHeight()

Returns the height of the horizontal scroll bar.

Returns:int

the height of the horizontal scroll bar

See Also
ScrollPane#getHScrollbarHeight()
getVScrollbarWidthback to summary
public int getVScrollbarWidth()

Returns the width of the vertical scroll bar.

Returns:int

the width of the vertical scroll bar

See Also
ScrollPane#getVScrollbarWidth()
setScrollPositionback to summary
public void setScrollPosition(int x, int y)

Sets the scroll position of the child.

Parameters
x:int

the X coordinate of the scroll position

y:int

the Y coordinate of the scroll position

See Also
ScrollPane#setScrollPosition(int, int)
setUnitIncrementback to summary
public void setUnitIncrement(Adjustable adj, int u)

Sets the unit increment of one of the scroll pane's adjustables.

Parameters
adj:Adjustable

the scroll pane adjustable object

u:int

the unit increment

See Also
ScrollPaneAdjustable#setUnitIncrement(int)
setValueback to summary
public void setValue(Adjustable adj, int v)

Sets the value for one of the scroll pane's adjustables.

Parameters
adj:Adjustable

the scroll pane adjustable object

v:int

the value to set