Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic Treelayout at runtime (Read 2510 times)
girivc
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 3
Joined: Oct 20th, 2008
Treelayout at runtime
Oct 20th, 2008 at 6:56am
Print Post  
Hi,
I'm creating shapenodes at runtime for parents and childs. I need to get the treeview structure at runtime without specifying the Bounds for each nodes and without specifying DiagramLink for parent and child. how do I do that?

Because If I specify bounds to each nodes, then I have to keep track of all the previous node x and y coordinates in order to place the next node.

help me out.
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Treelayout at runtime
Reply #1 - Oct 20th, 2008 at 8:57am
Print Post  
Hi,

Why not use the TreeLayout class? Isn't it what you refer to in the Subject line? You will have to create the DiagramLink objects though, otherwise TreeLayout doesn't have any way to infer the parent-child relationships in your diagram. You can delete the links or make them invisible after applying the layout if you don't want them in the final diagram.

I hope that helps,
Stoyan
  
Back to top
 
IP Logged
 
girivc
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 3
Joined: Oct 20th, 2008
Re: Treelayout at runtime
Reply #2 - Oct 20th, 2008 at 9:37am
Print Post  
Hi Stoyan,
Thanks, its working with DiagramLink.
how do I specify the Length for DiagramLink or the distance between the nodes?
(treelayout is taking default distance now)
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: Treelayout at runtime
Reply #3 - Oct 20th, 2008 at 10:08am
Print Post  
Set TreeLayout.NodeDistance and TreeLayout.LevelDistance.

Stoyan
  
Back to top
 
IP Logged
 
girivc
YaBB Newbies
*
Offline


I love YaBB 1G - SP1!

Posts: 3
Joined: Oct 20th, 2008
Re: Treelayout at runtime
Reply #4 - Oct 20th, 2008 at 10:55am
Print Post  
Thank You Stoyan Grin
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint