public class GridLayout extends Layout
Modifier and Type | Field and Description |
---|---|
protected boolean |
analyze |
protected int |
cols |
protected int |
rows |
m_anchor, m_bounds, m_bpts, m_insets, m_margin, m_tmpa, m_tmpb
m_group
DEFAULT_STEP_TIME, INFINITY
Constructor and Description |
---|
GridLayout(java.lang.String group)
Create a new GridLayout without preset dimensions.
|
GridLayout(java.lang.String group,
int nrows,
int ncols)
Create a new GridLayout using the specified grid dimensions.
|
Modifier and Type | Method and Description |
---|---|
static int[] |
analyzeGraphGrid(TupleSet ts)
Analyzes a set of nodes to try and determine grid dimensions.
|
int |
getNumCols()
Get the number of grid columns.
|
int |
getNumRows()
Get the number of grid rows.
|
void |
run(double frac)
Runs this Action, triggering whatever processing this Action performs.
|
void |
setNumCols(int cols)
Set the number of grid columns.
|
void |
setNumRows(int rows)
Set the number of grid rows.
|
getLayoutAnchor, getLayoutBounds, setLayoutAnchor, setLayoutBounds, setMargin, setX, setY
getGroup, setGroup
getVisualization, run, setVisualization
addActivityListener, alwaysRunAfter, cancel, fireActivityCancelled, fireActivityFinished, fireActivityScheduled, fireActivityStarted, fireActivityStepped, getDuration, getNextTime, getPace, getPacingFunction, getStartTime, getStepTime, getStopTime, isEnabled, isRunning, isScheduled, removeActivityListener, run, runAfter, runAt, setDuration, setEnabled, setPacingFunction, setStartTime, setStepTime
public GridLayout(java.lang.String group)
group
- the data group to layout. In this automatic grid
analysis configuration, the group must resolve to a set of
graph nodes.public GridLayout(java.lang.String group, int nrows, int ncols)
group
- the data group to layoutnrows
- the number of rows of the gridncols
- the number of columns of the gridpublic void run(double frac)
Action
run
in class GroupAction
frac
- the fraction of this Action's duration that has elapsed.Action.run(double)
public static int[] analyzeGraphGrid(TupleSet ts)
ts
- TupleSet ts a set of nodes to analyze. Contained tuples
must implement be Node instances.public int getNumCols()
public void setNumCols(int cols)
cols
- the number of grid columns to usepublic int getNumRows()
public void setNumRows(int rows)
rows
- the number of grid rows to useCopyright ? 2013 Regents of the University of California