| java.lang.Object javax.swing.ScrollPaneLayout com.jidesoft.swing.SimpleScrollPaneLayout
SimpleScrollPaneLayout | class SimpleScrollPaneLayout extends ScrollPaneLayout (Code) | | The layout manager used by SimpleScrollPaneLayout .
|
layoutContainer | public void layoutContainer(Container parent)(Code) | | Lays out the scrollpane. The positioning of components depends on
the following constraints:
- The row header, if present and visible, gets its preferred
width and the viewport's height.
- The column header, if present and visible, gets its preferred
height and the viewport's width.
- If a vertical scrollbar is needed, i.e. if the viewport's extent
height is smaller than its view height or if the
displayPolicy
is ALWAYS, it's treated like the row header with respect to its
dimensions and is made visible.
- If a horizontal scrollbar is needed, it is treated like the
column header (see the paragraph above regarding the vertical scrollbar).
- If the scrollpane has a non-
null
viewportBorder , then space is allocated for that.
- The viewport gets the space available after accounting for
the previous constraints.
- The corner components, if provided, are aligned with the
ends of the scrollbars and headers. If there is a vertical
scrollbar, the right corners appear; if there is a horizontal
scrollbar, the lower corners appear; a row header gets left
corners, and a column header gets upper corners.
Parameters: parent - the Container to lay out |
minimumLayoutSize | public Dimension minimumLayoutSize(Container parent)(Code) | | The minimum size of a ScrollPane is the size of the insets
plus minimum size of the viewport, plus the scrollpane's
viewportBorder insets, plus the minimum size
of the visible headers, plus the minimum size of the
scrollbars whose displayPolicy isn't NEVER.
Parameters: parent - the Container that will be laid out a Dimension object specifying the minimum size |
preferredLayoutSize | public Dimension preferredLayoutSize(Container parent)(Code) | | The preferred size of a ScrollPane is the size of the insets,
plus the 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.
Note that the rowHeader is calculated as part of the preferred width
and the colHeader is calculated as part of the preferred size.
Parameters: parent - the Container that will be laid out a Dimension object specifying the preferred size of theviewport and any scrollbars See Also: javax.swing.ViewportLayout See Also: java.awt.LayoutManager |
|
|