A IComparer<T> that compares two nodes with respect to their weight value defined via the IDataProvider registered with NODE_WEIGHT_DP_KEY.
Remarks
Nodes are sorted in descending order, i.e., nodes with a higher weight (and consequently larger area in the tree map) are placed first. The sum of the child weights is used as the weight value for nodes that have children.
Type Details
- yfiles module
- layout-tree
- yfiles-umd modules
- layout-orthogonal-compact, layout-orthogonal, layout-tree, layout
- Legacy UMD name
- yfiles.tree.NodeWeightComparer
To sort nodes in ascending order, subclass this IComparer<T> and swap the sign of the comparison method return value.