MinimumNodeSizeStage enforces a given minimum width/height of the nodes of a graph during the layout process.
Remarks
It temporarily enlarges nodes whose width/height is below the specified minimum values.
This ILayoutStage is especially useful to prevent that the core layout algorithm has to handle zero-sized nodes or nodes with negative sizes.
Type Details
- yfiles module
- layout-core
- yfiles-umd modules
- All layout modules, view-layout-bridge
- Legacy UMD name
- yfiles.layout.MinimumNodeSizeStage
Constructors
Creates a new MinimumNodeSizeStage instance using the given core layout algorithm along with a specific minimum width and height for the nodes.
Parameters
A map of options to pass to the method.
- coreLayout - ILayoutAlgorithm
- the core layout routine
- minWidth - number
- the minimum width of nodes that should be enforced
- minHeight - number
- the minimum height of nodes that should be enforced
Creates a new MinimumNodeSizeStage instance using the given core layout algorithm.
Remarks
1
wide and 1
high.Parameters
A map of options to pass to the method.
- coreLayout - ILayoutAlgorithm
- the core routine
Properties
Gets or sets the core layout algorithm that is wrapped by this stage.
Methods
Resizes all nodes that are smaller than the specified minimum size to that minimum size, executes the core layout algorithm and restores the original sizes afterwards.
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