This layout stage can be used for automatically assigning SwimlaneDescriptor instances to nodes by treating top-level group nodes as swimlanes.
Remarks
This stage will modify the hierarchy by temporarily removing the top-level group nodes and assigning corresponding descriptors to the remaining nodes. After running the core layout, the top-level group nodes will be arranged to function as swimlanes. This class allows using the current coordinates of the group nodes to arrange the swimlanes from sketch. Also, the spacing between swimlanes may be specified.
This stage can be appended to the HierarchicLayout.
Default Values of Properties
orderSwimlanesFromSketch | false | The order of the swimlanes is not determined from the current sketch. |
spacing | 0.0d |
Type Details
- yfiles module
- layout-hierarchic
- yfiles-umd modules
- layout-familytree, layout-hierarchic, layout-radial, layout
- Legacy UMD name
- yfiles.hierarchic.TopLevelGroupToSwimlaneStage
See Also
Constructors
Creates a new instance of TopLevelGroupToSwimlaneStage with the default settings.
Parameters
A map of options to pass to the method.
- spacing - number
The spacing between the swimlanes. This option sets the spacing property on the created object.
- orderSwimlanesFromSketch - boolean
Whether or not the order of the swimlanes should be determined based on the current sketch. This option sets the orderSwimlanesFromSketch property on the created object.
- coreLayout - ILayoutAlgorithm
The core layout algorithm that is wrapped by this stage. This option sets the coreLayout property on the created object.
Properties
Gets or sets the core layout algorithm that is wrapped by this stage.
Gets or sets the spacing between the swimlanes.
Remarks
0
.Default Value
0.0d
.Throws
- Exception({ name: 'ArgumentError' })
- if the spacing is negative
Sample Graphs
Methods
Calculates the layout by automatically assigning SwimlaneDescriptor instances to nodes and treating top-level group nodes as swimlanes.
Parameters
A map of options to pass to the method.
- graph - LayoutGraph
- the input graph
See Also
Implements
Invokes the layout process of the core layout algorithm.
Remarks
Parameters
A map of options to pass to the method.
- graph - LayoutGraph
- the input graph