Where Am I? Class Hierarchy (JFC) All Classes (JFC)

Class com.sun.java.swing.ScrollPaneLayout

java.lang.Object
   |
   +----com.sun.java.swing.ScrollPaneLayout

public class ScrollPaneLayout
extends Object
implements LayoutManager, ScrollPaneConstants, Serializable

The layout manager used by JScrollPane. JScrollPaneLayout is responsible for nine components: a viewport, two scrollbars, a row header, a column header, and four "corner" components.

Warning: serialized objects of this class will not be compatible with future swing releases. The current serialization support is appropriate for short term storage or RMI between Swing1.0 applications. It will not be possible to load serialized Swing1.0 objects with future releases of Swing. The JDK1.2 release of Swing will be the compatibility baseline for the serialized form of Swing objects.


Variable Index

colHead
hsb
hsbPolicy
lowerLeft
lowerRight
rowHead
upperLeft
upperRight
viewport
vsb
vsbPolicy

Constructor Index

ScrollPaneLayout()

Method Index

addLayoutComponent(String, Component)
addSingletonComponent(Component, Component)
Only one of these is allowed, remove the old one if neccessary.
getColumnHeader()
getCorner(String)
getHorizontalScrollBar()
getHorizontalScrollBarPolicy()
getRowHeader()
getVerticalScrollBar()
getVerticalScrollBarPolicy()
getViewport()
getViewportBorderBounds(JScrollPane)
layoutContainer(Container)
Layout the scrollpane according to the following constraints:

Variables

viewport
 protected JViewport viewport
vsb
 protected JScrollBar vsb
hsb
 protected JScrollBar hsb
rowHead
 protected JViewport rowHead
colHead
 protected JViewport colHead
lowerLeft
 protected Component lowerLeft
lowerRight
 protected Component lowerRight
upperLeft
 protected Component upperLeft
upperRight
 protected Component upperRight
vsbPolicy
 protected int vsbPolicy
hsbPolicy
 protected int hsbPolicy

Constructors

ScrollPaneLayout
 public ScrollPaneLayout()

Methods

addSingletonComponent
 protected Component addSingletonComponent(Component oldC,
                                           Component newC)
Only one of these is allowed, remove the old one if neccessary.

addLayoutComponent
 public void addLayoutComponent(String s,
                                Component c)
removeLayoutComponent
 public void removeLayoutComponent(Component c)
getVerticalScrollBarPolicy
 public int getVerticalScrollBarPolicy()
setVerticalScrollBarPolicy
 public void setVerticalScrollBarPolicy(int x)
getHorizontalScrollBarPolicy
 public int getHorizontalScrollBarPolicy()
setHorizontalScrollBarPolicy
 public void setHorizontalScrollBarPolicy(int x)
getViewport
 public JViewport getViewport()
getHorizontalScrollBar
 public JScrollBar getHorizontalScrollBar()
getVerticalScrollBar
 public JScrollBar getVerticalScrollBar()
getRowHeader
 public JViewport getRowHeader()
getColumnHeader
 public JViewport getColumnHeader()
getCorner
 public Component getCorner(String key)
preferredLayoutSize
 public Dimension preferredLayoutSize(Container parent)
The preferred size of a ScrollPane is the size of the insets plus preferred size of the viewport plus the preferred size of the visible headers, plus the preferred size of the scrollbars that will appear given the current view and the current scrollbar displayPolicies.

Returns:
The preferred size of the viewport and any scrollbars.
See Also:
ViewportLayout, LayoutManager
minimumLayoutSize
 public Dimension minimumLayoutSize(Container parent)
The minimum size of a ScrollPane is the size of the insets plus minimum size of the viewport, plus the scrollpanes viewportBorder insets, plus the minimum size of the visible headers, plus the minimum size of the scrollbars whose displayPolicy isn't NEVER.

layoutContainer
 public void layoutContainer(Container parent)
Layout the scrollpane according to the following constraints:

getViewportBorderBounds
 public Rectangle getViewportBorderBounds(JScrollPane sp)

Where Am I? Class Hierarchy (JFC) All Classes (JFC)