Package org.jfree.ui
Class OverlayLayout
- java.lang.Object
-
- org.jfree.ui.OverlayLayout
-
- All Implemented Interfaces:
java.awt.LayoutManager
public final class OverlayLayout extends java.lang.Object implements java.awt.LayoutManager
A simple layoutmanager to overlay all components of a parent.This layout manager acts similar to the card layout, but all children of the parent band have the same size and all children can be visible at the same time.
- Author:
- Thomas Morgner
-
-
Constructor Summary
Constructors Constructor Description OverlayLayout()DefaultConstructor.OverlayLayout(boolean ignoreInvisible)Creates a new instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddLayoutComponent(java.lang.String name, java.awt.Component comp)If the layout manager uses a per-component string, adds the componentcompto the layout, associating it with the string specified byname.voidlayoutContainer(java.awt.Container parent)Lays out the specified container.java.awt.DimensionminimumLayoutSize(java.awt.Container parent)Calculates the minimum size dimensions for the specified container, given the components it contains.java.awt.DimensionpreferredLayoutSize(java.awt.Container parent)Calculates the preferred size dimensions for the specified container, given the components it contains.voidremoveLayoutComponent(java.awt.Component comp)Removes the specified component from the layout.
-
-
-
Constructor Detail
-
OverlayLayout
public OverlayLayout(boolean ignoreInvisible)
Creates a new instance.- Parameters:
ignoreInvisible- whether to ignore invisible components when computing the layout.
-
OverlayLayout
public OverlayLayout()
DefaultConstructor.
-
-
Method Detail
-
addLayoutComponent
public void addLayoutComponent(java.lang.String name, java.awt.Component comp)
If the layout manager uses a per-component string, adds the componentcompto the layout, associating it with the string specified byname.- Specified by:
addLayoutComponentin interfacejava.awt.LayoutManager- Parameters:
name- the string to be associated with the componentcomp- the component to be added
-
removeLayoutComponent
public void removeLayoutComponent(java.awt.Component comp)
Removes the specified component from the layout.- Specified by:
removeLayoutComponentin interfacejava.awt.LayoutManager- Parameters:
comp- the component to be removed
-
layoutContainer
public void layoutContainer(java.awt.Container parent)
Lays out the specified container.- Specified by:
layoutContainerin interfacejava.awt.LayoutManager- Parameters:
parent- the container to be laid out
-
minimumLayoutSize
public java.awt.Dimension minimumLayoutSize(java.awt.Container parent)
Calculates the minimum size dimensions for the specified container, given the components it contains.- Specified by:
minimumLayoutSizein interfacejava.awt.LayoutManager- Parameters:
parent- the component to be laid out- Returns:
- the minimum size computed for the parent.
- See Also:
preferredLayoutSize(java.awt.Container)
-
preferredLayoutSize
public java.awt.Dimension preferredLayoutSize(java.awt.Container parent)
Calculates the preferred size dimensions for the specified container, given the components it contains.- Specified by:
preferredLayoutSizein interfacejava.awt.LayoutManager- Parameters:
parent- the container to be laid out- Returns:
- the preferred size computed for the parent.
- See Also:
minimumLayoutSize(java.awt.Container)
-
-