javazoom.jlgui.player.amp.skin
Class AbsoluteLayout
java.lang.Object
javazoom.jlgui.player.amp.skin.AbsoluteLayout
- LayoutManager2, java.io.Serializable
public class AbsoluteLayout
extends java.lang.Object
implements LayoutManager2, java.io.Serializable
AbsoluteLayout is a LayoutManager that works as a replacement for "null" layout to
allow placement of components in absolute positions.
void | addLayoutComponent(Component comp, Object constr) - Adds the specified component to the layout, using the specified
constraint object.
|
void | addLayoutComponent(String name, Component comp) - Adds the specified component with the specified name to
the layout.
|
float | getLayoutAlignmentX(Container target) - Returns the alignment along the x axis.
|
float | getLayoutAlignmentY(Container target) - Returns the alignment along the y axis.
|
void | invalidateLayout(Container target) - Invalidates the layout, indicating that if the layout manager
has cached information it should be discarded.
|
void | layoutContainer(Container parent) - Lays out the container in the specified panel.
|
Dimension | maximumLayoutSize(Container target) - Returns the maximum size of this component.
|
Dimension | minimumLayoutSize(Container parent) - Calculates the minimum dimension for the specified
panel given the components in the specified parent container.
|
Dimension | preferredLayoutSize(Container parent) - Calculates the preferred dimension for the specified
panel given the components in the specified parent container.
|
void | removeLayoutComponent(Component comp) - Removes the specified component from the layout.
|
constraints
protected java.util.Hashtable constraints
A mapping
addLayoutComponent
public void addLayoutComponent(Component comp,
Object constr)
Adds the specified component to the layout, using the specified
constraint object.
comp
- the component to be addedconstr
- where/how the component is added to the layout.
addLayoutComponent
public void addLayoutComponent(String name,
Component comp)
Adds the specified component with the specified name to
the layout.
name
- the component namecomp
- the component to be added
getLayoutAlignmentX
public float getLayoutAlignmentX(Container target)
Returns the alignment along the x axis. This specifies how
the component would like to be aligned relative to other
components. The value should be a number between 0 and 1
where 0 represents alignment along the origin, 1 is aligned
the furthest away from the origin, 0.5 is centered, etc.
getLayoutAlignmentY
public float getLayoutAlignmentY(Container target)
Returns the alignment along the y axis. This specifies how
the component would like to be aligned relative to other
components. The value should be a number between 0 and 1
where 0 represents alignment along the origin, 1 is aligned
the furthest away from the origin, 0.5 is centered, etc.
invalidateLayout
public void invalidateLayout(Container target)
Invalidates the layout, indicating that if the layout manager
has cached information it should be discarded.
layoutContainer
public void layoutContainer(Container parent)
Lays out the container in the specified panel.
parent
- the component which needs to be laid out
maximumLayoutSize
public Dimension maximumLayoutSize(Container target)
Returns the maximum size of this component.
java.awt.Component.getMinimumSize()
, java.awt.Component.getPreferredSize()
, LayoutManager
minimumLayoutSize
public Dimension minimumLayoutSize(Container parent)
Calculates the minimum dimension for the specified
panel given the components in the specified parent container.
parent
- the component to be laid out
preferredLayoutSize
public Dimension preferredLayoutSize(Container parent)
Calculates the preferred dimension for the specified
panel given the components in the specified parent container.
parent
- the component to be laid out
removeLayoutComponent
public void removeLayoutComponent(Component comp)
Removes the specified component from the layout.
comp
- the component to be removed
JavaZOOM 1999-2006