I wanted to have a parent group of fixed size which can contain many child nodes.Also, what I want is that as the child nodes increase, the parent group size should not increase ,but the contents inside the parent should scale(shrink) accordingly.
Similarly if i delete any children nodes, the other remaining nodes inside the parent group should scale(expand) according to the space available in the parent group.
So,to summarize,i want 2 things,
A fixed group
Scalability inside each individual group according to the size and number of children nodes.
Thanks for providing some screenshots. But it’s still unclear in my mind exactly what you want to have happen. I’m assuming that the number of member Nodes changes over time, and at each such time you want those nodes to fit inside your Group.
It’s clear that you want to set the positions or locations of the member Nodes to be closer to each other or farther apart. It isn’t clear if you want to change their effective size by actually changing their desiredSize (or the width and height), either of the whole Node or of the Node.resizeObject. Or whether you just want to set their scale.
My guess at this time is that you want a custom Layout as your Group.layout. That layout will know the width of the group and you know what padding and spacing you want to maintain, so you can calculate what position you want each node to be at and what size you want each node to be. If the nodes are naturally different sizes from each other you’ll probably want to maintain relative sizes, but I don’t know what you want to do.