public class BoxLayoutAlgorithm extends GridLayoutAlgorithm
Modifier and Type | Field and Description |
---|---|
static int |
HORIZONTAL |
static int |
VERTICAL |
aspectRatio, childrenHeight, childrenWidth, cols, colWidth, numChildren, offsetX, offsetY, rowHeight, rowPadding, rows
Constructor and Description |
---|
BoxLayoutAlgorithm() |
BoxLayoutAlgorithm(int orientation) |
Modifier and Type | Method and Description |
---|---|
protected int[] |
calculateNumberOfRowsAndCols(int numChildren,
double boundX,
double boundY,
double boundWidth,
double boundHeight)
Calculates and returns an array containing the number of columns,
followed by the number of rows
|
int |
getOrientation() |
void |
setOrientation(int orientation) |
applyLayout, applyLayoutInternal, calculateGrid, calculateNodeSize, calculateNumberOfRowsAndCols_rectangular, calculateNumberOfRowsAndCols_square, getLayoutContext, isResizing, setAspectRatio, setLayoutContext, setResizing, setRowPadding
public static final int HORIZONTAL
public static final int VERTICAL
public BoxLayoutAlgorithm()
public BoxLayoutAlgorithm(int orientation)
public int getOrientation()
public void setOrientation(int orientation)
protected int[] calculateNumberOfRowsAndCols(int numChildren, double boundX, double boundY, double boundWidth, double boundHeight)
GridLayoutAlgorithm
calculateNumberOfRowsAndCols
in class GridLayoutAlgorithm
Copyright (c) 2014 itemis AG and others. All rights reserved.