Compact Tabular Layout
This demo shows how to configure the TabularLayout to create compact
drawings.
The algorithm tries to calculate an arrangement that minimizes edge lengths. Since tabular
layout only supports straight-line edges, EdgeRouter is used to
calculate the final edge paths.
Selecting the Preserve Aspect Ratio button in the toolbar switches the layout
mode to FIXED_SIZE, maintaining a layout
aspect ratio similar to that of the GraphComponent. In contrast,
deselecting it uses AUTO_SIZE mode for
maximum compactness.
In FIXED_SIZE mode, the layout algorithm requires a
LayoutGrid to define the layout's columns and rows. In
AUTO_SIZE mode, a grid is optional, though it can be used to specify spacing
between auto-calculated columns and rows.
Things to Try
- Click the button in the toolbar to observe the effect.
Documentation