Page Index Toggle Pages: 1 Send TopicPrint
Normal Topic LayeredLayout: how to keep arrows horizontal? (Read 1361 times)
Artem_Kliatchkine
YaBB Newbies
*
Offline



Posts: 1
Joined: Aug 22nd, 2006
LayeredLayout: how to keep arrows horizontal?
Aug 22nd, 2006 at 10:41am
Print Post  
Please, have a look at the diagram overview:



To make this diagram I used LayeredLayout class. Please, look at the red-marked area in the bottom. The arrow turns up while it seems to be not necessary - there is only one child node. There are other such arrows on the diagram. Obviously it was made to keep a space. But it makes the diagram messy. I would like to keep arrows horizontal when it's possible. Is there a way to  do this? I've already tried nearly all settings of LayeredLayout but didn't succeed.

Btw, I have another question. Note the gray root node. It's gray because it is actually a ControlHost. It would be nice to show at least the node's fill color if displaying control's contents is impossible.

Thanks,
Artem
  
Back to top
 
IP Logged
 
Stoyo
God Member
*****
Offline


MindFusion support

Posts: 13230
Joined: Jul 20th, 2005
Re: LayeredLayout: how to keep arrows horizontal?
Reply #1 - Aug 22nd, 2006 at 11:36am
Print Post  
Hi,

I think you could use the TreeLayout with this diagram; it should keep the arrows horizontal when possible. LayeredLayout relies on some "center of mass" calculations to find out a position for a node, and that position depends on several nodes, and not only on the direct parent position.

Handle the PaintControlHost event to provide your representation of the root node when printing it or displaying it in the overview window.

Stoyan
  
Back to top
 
IP Logged
 
Page Index Toggle Pages: 1
Send TopicPrint