Is it possible to have a group save it’s nodes’ positions on collapse? Here is my groupTemplate:
myDiagram.groupTemplate =
Make(go.Group, "Auto",
{
layout: Make(go.GridLayout, { wrappingColumn: 1 }),
selectable: true,
isSubGraphExpanded: true,
},
Make(go.Shape, "Rectangle", // surrounds the Vertical panel
{
fill: "rgba(128,128,128,0.33)",
fromSpot: go.Spot.Bottom,
toSpot: go.Spot.Top,
portId: ""
}
),
Make(go.Panel, "Vertical",
Make("SubGraphExpanderButton", { alignment: go.Spot.Left, margin: 5, width:30, height:30 }),
Make(go.TextBlock, // group title
{ font: "Bold 12pt Sans-Serif", margin: 10 },
new go.Binding("text", "label")
),
Make(go.Placeholder, // represents the area of all member parts,
{ padding: 5 } // with some extra padding around them
)
)
);
But if a user drags the nodes around that are in the group and collapses the group, when it is expanded the nodes all have their original position. Is there a way to configure this so the positions are retained?
Thanks!