Class OverlapLayout
java.lang.Object
gg.xp.xivsupport.gui.tables.renderers.OverlapLayout
- All Implemented Interfaces:
LayoutManager,LayoutManager2,Serializable
- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionConvenience constructor to provide for "stacking" of components.OverlapLayout(Point overlapPosition) Convenience constructor.OverlapLayout(Point overlapPosition, boolean overlapAbove) Create an overlapping layout. -
Method Summary
Modifier and TypeMethodDescriptionvoidaddLayoutComponent(Component component, Object constraint) voidaddLayoutComponent(String name, Component comp) Adds the specified component with the specified name to the layout.intconvertIndex(int index) When components are overlapped above the ZOrder of each component is changed resulting in the components position in the container being changed.getConstraints(Component component) Gets the constraints for the specified component.floatgetLayoutAlignmentX(Container parent) Returns the alignment along the x axis.floatgetLayoutAlignmentY(Container parent) Returns the alignment along the y axis.Get the overlapping position of each componentGet the popup insetsvoidinvalidateLayout(Container target) Invalidates the layout, indicating that if the layout manager has cached information it should be discarded.booleanGet the include invisible propertyvoidlayoutContainer(Container parent) Lays out the specified container using this layout.maximumLayoutSize(Container target) There is no maximum.minimumLayoutSize(Container parent) Determine the minimum size on the ContainerpreferredLayoutSize(Container parent) Determine the preferred size on the ContainervoidremoveLayoutComponent(Component component) Removes the specified component from the layout.voidsetIncludeInvisible(boolean includeInvisible) Controls whether spaces should reserved for invisible components in the containervoidsetOverlapPosition(Point overlapPosition) Specify the position where the overlapped component should be painted.voidsetPopupInsets(Insets popupInsets) Define extra space to be reserved by the container.toString()Returns the string representation of this column layout's values.
-
Field Details
-
POP_UP
-
POP_DOWN
-
-
Constructor Details
-
OverlapLayout
public OverlapLayout()Convenience constructor to provide for "stacking" of components. Each component will be stacked above the previous component and sized to fill the space of the parent container. -
OverlapLayout
Convenience constructor. Each component will overlap above the previous component.- Parameters:
overlapPosition- a Point defining the relative amount of overlap
-
OverlapLayout
Create an overlapping layout.- Parameters:
overlapPosition- a Point defining the relative amount of overlapoverlapAbove- when true components are painted above the previous component, otherwise they are painted below.
-
-
Method Details
-
convertIndex
public int convertIndex(int index) When components are overlapped above the ZOrder of each component is changed resulting in the components position in the container being changed. For example when you add a component to the end of the container it will be moved to the beginning. If you then try to access the component using Component.componentAt(), you will get the first component, not the last.This method will convert the index to you access the proper component.
- Parameters:
index- the index to convert
-
isIncludeInvisible
public boolean isIncludeInvisible()Get the include invisible property- Returns:
- the include invisible property
-
setIncludeInvisible
public void setIncludeInvisible(boolean includeInvisible) Controls whether spaces should reserved for invisible components in the container- Parameters:
includeInvisible- when true, space is reserved otherwise the component is not included in the layout sizing
-
getOverlapPosition
Get the overlapping position of each component- Returns:
- the Point representing the overlapped position
-
setOverlapPosition
Specify the position where the overlapped component should be painted.- Parameters:
overlapPosition- the position where the next component is painted
-
getPopupInsets
Get the popup insets- Returns:
- the popup insets
-
setPopupInsets
Define extra space to be reserved by the container. This will allow components to be "popped up" if required. Generally space would only be reserved on one side of the container.- Parameters:
popupInsets- Insets defining extra space for a particular side of the container.
-
getConstraints
Gets the constraints for the specified component.- Parameters:
component- the component to be queried- Returns:
- the constraint for the specified component, or null if component is null or is not present in this layout
-
addLayoutComponent
Adds the specified component with the specified name to the layout.- Specified by:
addLayoutComponentin interfaceLayoutManager- Parameters:
name- the name of the componentcomp- the component to be added
-
addLayoutComponent
- Specified by:
addLayoutComponentin interfaceLayoutManager2
-
removeLayoutComponent
Removes the specified component from the layout.- Specified by:
removeLayoutComponentin interfaceLayoutManager- Parameters:
component- the component to be removed
-
minimumLayoutSize
Determine the minimum size on the Container- Specified by:
minimumLayoutSizein interfaceLayoutManager- Parameters:
parent- the container in which to do the layout- Returns:
- the minimum dimensions needed to lay out the subcomponents of the specified container
-
preferredLayoutSize
Determine the preferred size on the Container- Specified by:
preferredLayoutSizein interfaceLayoutManager- Parameters:
parent- the container in which to do the layout- Returns:
- the preferred dimensions to lay out the subcomponents of the specified container
-
layoutContainer
Lays out the specified container using this layout.- Specified by:
layoutContainerin interfaceLayoutManager- Parameters:
parent- the container in which to do the layout
-
maximumLayoutSize
There is no maximum.- Specified by:
maximumLayoutSizein interfaceLayoutManager2
-
getLayoutAlignmentX
Returns the alignment along the x axis. Use center alignment.- Specified by:
getLayoutAlignmentXin interfaceLayoutManager2
-
getLayoutAlignmentY
Returns the alignment along the y axis. Use center alignment.- Specified by:
getLayoutAlignmentYin interfaceLayoutManager2
-
invalidateLayout
Invalidates the layout, indicating that if the layout manager has cached information it should be discarded.- Specified by:
invalidateLayoutin interfaceLayoutManager2
-
toString
Returns the string representation of this column layout's values.
-