public class IlvStackerLayout extends Object implements IlvLayoutManager
Constructor and Description |
---|
IlvStackerLayout()
Creates a new instance of
IlvStackerLayout |
IlvStackerLayout(IlvInputStream stream)
Reads the object from an
IlvInputStream . |
IlvStackerLayout(int orientation,
int alignment,
int spacing)
Creates a new stacker graphic for the attribute or representation
object, with the given characteristics for orientation, alignment and
spacing.
|
Modifier and Type | Method and Description |
---|---|
void |
attach(IlvAttachable target)
Sets the constraints defined by the supplied
IlvAttachable |
protected void |
checkValues()
This method just checks if the values defined for the stacker
characteristics are valid.
|
Object |
clone()
Creates a copy of this object.
|
protected void |
computeChildrenAttachmentCoordinates(IlvAttachable target)
Computes the attachment coordinates of the children.
|
int |
getAlignment()
Returns the alignment used in the stacker children.
|
int |
getOrientation()
Returns the current orientation.
|
int |
getSpacing()
Returns the spacing between child elements.
|
void |
layoutGroup(IlvAttachable target)
Lays out the specified
IlvAttachable container. |
void |
removeConstraints(IlvAttachable element)
Removes the specified
IlvAttachable from the layout. |
void |
reset()
Remove all the constraints
|
boolean |
resizeFirstChildOnly()
Returns always
false |
void |
setAlignment(int alignment)
Returns the alignment used in the stacker children.
|
void |
setConstraints(IlvAttachable element,
Object constraints)
The supplied
IlvAttachable is added at the end of the stack. |
void |
setOrientation(int orientation)
Returns the current orientation.
|
void |
setSpacing(int spacing)
Returns the spacing between child elements.
|
void |
write(IlvOutputStream stream)
Writes the attributes of a persistent object.
|
public IlvStackerLayout()
IlvStackerLayout
public IlvStackerLayout(int orientation, int alignment, int spacing)
orientation
- either SwingConstants.TOP
or SwingConstants.BOTTOM
or SwingConstants.LEFT
or SwingConstants.RIGHT
alignment
- either SwingConstants.TOP
or SwingConstants.BOTTOM
or SwingConstants.LEFT
or SwingConstants.RIGHT
or SwingConstants.CENTER
public IlvStackerLayout(IlvInputStream stream) throws IlvReadFileException
IlvInputStream
.stream
- The input stream.IlvReadFileException
- if the format is not correct.protected void checkValues()
public void setOrientation(int orientation)
public int getOrientation()
public void setAlignment(int alignment)
public int getAlignment()
public void setSpacing(int spacing)
public int getSpacing()
public void setConstraints(IlvAttachable element, Object constraints)
IlvAttachable
is added at the end of the stack.setConstraints
in interface IlvLayoutManager
element
- the IlvAttachable
to be addedconstraints
- where/how the component is added to the layout.public void removeConstraints(IlvAttachable element)
IlvAttachable
from the layout.removeConstraints
in interface IlvLayoutManager
element
- the IlvAttachable>/code> object to be removed.
public void layoutGroup(IlvAttachable target)
IlvAttachable
container.layoutGroup
in interface IlvLayoutManager
target
- the container to be laid outpublic void attach(IlvAttachable target)
IlvAttachable
attach
in interface IlvLayoutManager
target
- the container to be laid outIlvAttachable.getAttachables()
,
IlvAttachable.getConstraints()
protected void computeChildrenAttachmentCoordinates(IlvAttachable target)
target
- The container.public void reset()
reset
in interface IlvLayoutManager
public Object clone()
clone
in interface IlvLayoutManager
clone
in class Object
public boolean resizeFirstChildOnly()
false
resizeFirstChildOnly
in interface IlvLayoutManager
public void write(IlvOutputStream stream) throws IOException
write
in interface IlvPersistentObject
stream
- the output streamIOException
- thrown when an exception occurs during
the write operation for this object.© Copyright Rogue Wave Software, Inc. 1997, 2018. All Rights Reserved.