Folding With Merged Edges
This demo shows how to enable
collapsing and expanding of group nodes. This is provided
through class FoldingManager and its support classes. Additionally, a
MergingFoldingEdgeConverter is used to merge edges between group nodes.
Things to Try
-
Collapse one or more groups. The MergingFoldingEdgeConverter will merge
the edges such that only one edge connects any node connected to the folder node. The
label on the edge indicates how many edges were merged.
-
Add additional nodes to the groups by entering the respective group. Add edges between
nodes of separate group nodes and see the incrementing edge count.
- Add new groups and edges between child nodes.
GraphEditorInputMode provides the following default gestures for
collapse/expand:
-
Press ALT+LeftArrow or click the expand-button on the node's top left corner
to close (collapse) an open group node.
-
Press ALT+RightArrow or click the collapse-button on the node's top left
corner to open (expand) a closed group node.
- Press ALT+DownArrow to enter (navigate into) a group node.
- Press ALT+UpArrow to exit (navigate out of) a group node.
See the sources for details.