Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Hierarchical group structures (Read 1332 times)
kai-uwe.zoland
YaBB Newbies
*
Offline



Posts: 18
Joined: Sep 5th, 2008
Hierarchical group structures
Apr 12th, 2010 at 8:22am
Print Post  
Hi,

I have a further question about groups. As I understand, it is not possible to create a hierarchical group structure, where the same diagram node is the mainitem of two groups.

In our application we use the flowlayout algorithm on different level with small parts of the diagram and we do arrangements based on our hierarchical structure. In the flowlayout we have in most cases the keepgrouplayout property set to true. Now it happens that one node can be the mainitem of two groups. These groups are part of the hierarchical structure, one group is also a member of the other group. And this inner group should keep its layout, when the outer is arranged and the outer group should keep its layout, when the complete diagram is arranged. Is it possible for you, to extend the group handling, so one node can be mainitem of two groups, so this hierarchical structure can be handled inside the diagram?

I saw also, that there is a containernode class. So far I did not use this and I do not need the drag and drop feature of this class. Is it possible that this class can help with our problem? Does the containernode class work with the flowlayout algorithm? Are nodes inside a containernode ignored by the flowlayout algorithm? Can a link connect a node outside of a container and a node inside a container?

Thanks for your help.
Kai-Uwe
  
Back to top
WWWYIM  
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Hierarchical group structures
Reply #1 - Apr 12th, 2010 at 12:48pm
Print Post  
Hi,

From what I understand you arrange the diagram in two phases, first the groups using the Arrange(items) overload and then the whole diagram using KeepGroupLayout? In such case you could extend this with a recursion over your hierarchical group structure, where the innermost groups are arranged first, and their parent groups next. E.g. the method would first call itself recursively to arrange the child groups, and then arrange the current group before returning.

We don't plan extending the group handling. I suppose that's something you can do easily by adding an intermediate node as parent for the child group, where the node itself is a part of the outer group. It could be just temporary until the diagram is arranged, or it could be an always present invisible node.

Layout classes do not change the position of items inside containers. Using a Container to define the child group would not be much different that a ShapeNode + attached items. Links can connect to both outside and inside the container.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint