public class HexagonalGridLayout extends GridLayout
setRotated(boolean)
.setPoints()
with the PointList returned by
this LayoutManager's getPoints()
method. This LayoutManager does not
call setPoints()
, a method that causes an invalidation, on the
child IFigures. Instead, the LayoutManager directly modifies the PointList.Constructor and Description |
---|
HexagonalGridLayout()
The default constructor.
|
HexagonalGridLayout(int rows,
int columns)
A non-default constructor.
|
Modifier and Type | Method and Description |
---|---|
org.eclipse.draw2d.geometry.PointList |
getPoints()
Gets the PointList that should be used by child hexagon Figures
(PolygonShapes).
|
void |
layout(org.eclipse.draw2d.IFigure container)
Applies a hexagon-based layout to the container.
|
void |
setRotated(boolean rotated)
Sets whether or not the layout is rotated 90 degrees.
|
getConstraint, getHorizontalSpacing, getVerticalSpacing, setConstraint, setHorizontalSpacing, setVerticalSpacing
getMinimumSize, getPreferredSize, invalidate
public HexagonalGridLayout()
public HexagonalGridLayout(int rows, int columns)
rows
- The number of rows in the layout.columns
- The number of columns in the layout.public org.eclipse.draw2d.geometry.PointList getPoints()
setPoints(PointList)
with the value returned by this method.public void setRotated(boolean rotated)
rotated
- Whether or not to rotate the layout.public void layout(org.eclipse.draw2d.IFigure container)
layout
in interface org.eclipse.draw2d.LayoutManager
layout
in class GridLayout