I’m prefer to this:
http://gojs.net/latest/intro/panels.html
And I’m using :
$(go.Panel, go.Panel.Position, $(go.Placeholder, { padding: 5}))
But it’s not working
here is my groupTemplate:
var groupTempl = $(go.Group, “Auto”,
{
fromSpot: go.Spot.AllSides,
toSpot: go.Spot.AllSides,
isSubGraphExpanded:true
},
new go.Binding(“location”, “location”, function(locStringify){
return go.Point.parse(locStringify);
}).makeTwoWay(go.Point.stringify),
$(go.Shape, “Rectangle”, { fill: null, stroke: “#4472C4”, strokeWidth: 2 }),
$(go.Panel, go.Panel.Vertical, // title above Placeholder
$(go.Panel, go.Panel.Horizontal, // button next to
// TextBlock
{ stretch: go.GraphObject.Horizontal, margin: 1 },
$(“SubGraphExpanderButton”,
{ alignment: go.Spot.Right, margin: 5
}),
$(go.TextBlock,
{
alignment: go.Spot.Left,
editable: true,
margin: 5,
font: “bold 18px ‘Open Sans’”,
stroke: “#4472C4”
},
new go.Binding(“text”, “label”))
), // end Horizontal Panel
$(go.Panel, go.Panel.Position,
$(go.Placeholder,
{ padding: 5})
)
)
); // end Group
Sorry, i need to more specific my question:
For Example, i have:
Node A with Location(0,0) in Group B.
Node C with Location(0,0) not in any group.
What i want here is Node A not overlapping with Node C.
And Location of Node A belong GroupB 's Coordinate system