public class IlpGridLayoutParameters extends IlpGraphLayoutParameters
This class models the properties that can be configured for each object when using the Grid layout.
To customize per-object properties, the graph layout renderer must be enabled and configured to customize per-object properties.
IlvGridLayout
Constructor and Description |
---|
IlpGridLayoutParameters()
Default constructor
|
Modifier and Type | Method and Description |
---|---|
boolean |
apply(IlvGraphLayout layout,
IlpRepresentationObject ro,
IlvGraphic layoutProxy)
Applies the configuration that is stored in this bean into
the given layout for the given node.
|
int |
getHorizontalAlignment()
Returns the horizontal alignment style of an individual node.
|
int |
getIndex()
Returns the index of a node.
|
int |
getVerticalAlignment()
Returns the vertical alignment style of an individual node.
|
void |
reset()
Resets the configuration in this bean.
|
void |
setHorizontalAlignment(int align)
Sets the horizontal alignment style of an individual node.
|
void |
setIndex(int i)
Allows you to specify the index of a node.
|
void |
setVerticalAlignment(int align)
Sets the vertical alignment style of an individual node.
|
isFixed, isLayoutIgnored, setFixed, setLayoutIgnored
public void reset()
reset
in class IlpGraphLayoutParameters
public boolean apply(IlvGraphLayout layout, IlpRepresentationObject ro, IlvGraphic layoutProxy)
apply
in class IlpGraphLayoutParameters
layout
- Graph Layoutro
- Object to which the configuration will be appliedlayoutProxy
- Layout graphic object for a node or linkpublic void setIndex(int i)
Allows you to specify the index of a node. When the layout
is performed, the nodes for which indexes have been specified
are arranged on the bus in the order corresponding to their
index (starting in the upper-left corner with the smallest
index). The nodes for which indexes have not been specified
are arranged after them. You can specify the class variable
IlvBusLayout.NO_INDEX
as
an index value if you want to reset an index you previously
specified.
Note that index must not be negative. The values of the indexes for consecutive nodes are not necessarily consecutive. Only the order of the values is important.
i
- Node indexIlvGridLayout.setIndex(java.lang.Object, int)
public int getIndex()
setIndex(int)
public void setVerticalAlignment(int align)
Sets the vertical alignment style of an individual node.
This alignment style is used only if the global vertical alignment
is set to IlvGridLayout.MIXED
.
Otherwise, all nodes have the alignment style that is specified as
the global alignment style.
The parameter controls the vertical alignment of nodes either
inside their grid cell if the layout mode
(see IlvGridLayout.setLayoutMode(int)
)
is IlvGridLayout.TILE_TO_GRID_FIXED_WIDTH
or
IlvGridLayout.TILE_TO_GRID_FIXED_HEIGHT
, or
inside the rows if the layout mode is IlvGridLayout.TILE_TO_ROWS
.
This parameter is not used if the layout mode
(see IlvGridLayout.setLayoutMode(int)
) is
IlvGridLayout.TILE_TO_COLUMNS
.
Valid values are:
IlvGridLayout.CENTER
- the node is centered
in its grid cell or column.IlvGridLayout.TOP
- the node is aligned to
the top border of the cell or column.IlvGridLayout.BOTTOM
- the node is aligned
to the bottom border of the cell or column.The default value is IlvGridLayout.CENTER
.
align
- Vertical alignment style for this nodeIlvGridLayout.setVerticalAlignment(java.lang.Object, int)
public int getVerticalAlignment()
setVerticalAlignment(int)
public void setHorizontalAlignment(int align)
Sets the horizontal alignment style of an individual node.
This alignment style is used only if the global horizontal
alignment is set to IlvGridLayout.MIXED
.
Otherwise, all nodes have the alignment style that is specified as
the global alignment style.
The parameter controls the horizontal alignment of nodes either
inside their grid cell if the layout mode
(see IlvGridLayout.setLayoutMode(int)
) is
IlvGridLayout.TILE_TO_GRID_FIXED_WIDTH
or
IlvGridLayout.TILE_TO_GRID_FIXED_HEIGHT
, or
inside the columns if the layout mode is IlvGridLayout.TILE_TO_COLUMNS
This parameter is not used if the layout mode
(see IlvGridLayout.setLayoutMode(int)
)
is IlvGridLayout.TILE_TO_ROWS
.
Valid values are:
IlvGridLayout.CENTER
- the node is centered
in its grid cell or column.IlvGridLayout.LEFT
- the node is aligned to
the left border of the cell or column.IlvGridLayout.RIGHT
- the node is aligned to
the left border of the cell or column.The default value is IlvGridLayout.CENTER
.
align
- Horizontal alignment style for this nodeIlvGridLayout.setHorizontalAlignment(java.lang.Object, int)
public int getHorizontalAlignment()
setVerticalAlignment(int)
© Copyright 2024 Rogue Wave Software, Inc., a Perforce company.. All Rights Reserved.