documentationfor yFiles for HTML 3.0.0.3

GenericLayoutGridStage

This stage offers generic support for LayoutGrid structures so that a grid can be considered even when running a layout algorithm that natively does not support it.

Inheritance Hierarchy
LayoutStageBase
GenericLayoutGridStage
Implemented Interfaces

Remarks

It is not required to apply this stage when executing a layout algorithm that already supports the LayoutGrid natively, for example, HierarchicalLayout, OrganicLayout or EdgeRouter.

The stage performs the following steps:

  1. First it determines sub-components such that each component only contains nodes associated with the same grid cell. Nodes without associated grid cell are temporarily assigned to a suitable cell.
  2. Now this stage applies the specified coreLayout to each sub-component and, afterwards, reassembles the global layout grid structure. Since the sub-components do not contain nodes of different cells, the core layout algorithm doesn't require support for layout grid on its own.
  3. Finally, this stage routes edges that connect nodes of different sub-components by means of the specified inter-edge router. Note that such edges are temporarily hidden during the core layout runs.

Disabling property splitMultiCellComponents allows to switch to a mode where connected components are not split into smaller sub-components. Hence, a component may contain nodes of different grid cells and, thus, the specified coreLayout has to support layout grid structures by itself. In this case, this stage doesn't offer a generic layout grid support (since the core layout algorithm already has to support such structures). Instead it may speed up the layout calculation since the core layout algorithm is applied to different smaller graphs instead of a single, larger input graph.

Default Values of Properties

interEdgeRouternullInter-edges are routed as straight lines.
nodeLabelPlacementCONSIDERNode labels are included in the bounds of the grid cells.
splitMultiCellComponentstrueComponents with nodes of different layout grid cells are split.

Type Details

yFiles module
algorithms

See Also

Constructors

Properties

Methods

Constants