This is a migrated thread and some comments may be shown as answers.

Radial Tree layout doesn't respect container size

3 Answers 129 Views
Diagram
This is a migrated thread and some comments may be shown as answers.
Wipatel
Top achievements
Rank 1
Wipatel asked on 08 Oct 2014, 08:39 AM
Greetings, Telerik!

In out project we use diagram with all available types of layout.
Almost all layout types works great but radial tree behaves weird and it's unclear how the one can fix it without your help.
Mostly, we have a lot of containers in diagram and when radial tree is applied it looks fine, but when container that was placed above is expanded it is placed above and connected container isn't visible. Attached file can explain it better than thousand words.

In project we agreed to use next TreeLayoutSettings (regarding Radial tree)
StartRadialAngle = 1.0,
EndRadialAngle = 6.5,
RadialFirstLEvelSeparation = 150.0,
RadialSeparation = 150,
KeepComponentsInOneRadialLayout = true,
I believe that OrgTreeRouter means nothing when layout is being done.
Also we're filling collection of Roots for settings according to some rules (mostly the root will be the shape/container with outgoing connections).

Is it possible for radial tree to respect margins and place containers with some margins?

Thanks in advance! 

3 Answers, 1 is accepted

Sort by
0
Martin Ivanov
Telerik team
answered on 13 Oct 2014, 07:34 AM
Hello Wipatel,

Thank you for the attached images. However, it is not very clear for me what is your expected result and how you created your current visualization. Can you please send us a sample project demonstrating your implementation? This will help me in better understanding your scenario and assist you further. Also, it would be helpful if you can provide me with another image demonstrating the desired result and additional information about your scenario.

Thank you for any help you can provide.

Regards,
Martin
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
0
Wipatel
Top achievements
Rank 1
answered on 15 Oct 2014, 08:15 AM
Hello, Martin.
Thanks for a reply.

I attached a small example that might get you closer to my problem with Radial layout. (renamed *.7z archive).
When layout is rendered, the most items are visible and they don't hide each other. Each expand/collapse operation calls layout method.
When you expand any container above, then connected container is not moved anywhere so it is just partially visible, it just stays where it was rendered. 
Please, can you give any advice in order to achieve proper layouting? Or is it possible at all?

Regards!

0
Accepted
Martin Ivanov
Telerik team
answered on 20 Oct 2014, 08:07 AM
Hi Wipatel,

Currently, the reported behavior cannot be altered easily. However, you can try different combinations of settings for the TreeLayoutSettings and see if they will help you to adjust the layout properly. Another approach you can use is to subscribe for the DiagramLayoutComplete event of RadDiagram and re-position the overlapped shapes so that they are located on the expected positions.

For example, in the IsCollapsedChanged event handler you can get the collapsed/expanded container. Then in the DiagramLayoutCompleted you can get the containers that should be affected by the layout and modify their positions so that they don't overlap one another.

Regards,
Martin
Telerik
 

Check out the Telerik Platform - the only platform that combines a rich set of UI tools with powerful cloud services to develop web, hybrid and native mobile apps.

 
Tags
Diagram
Asked by
Wipatel
Top achievements
Rank 1
Answers by
Martin Ivanov
Telerik team
Wipatel
Top achievements
Rank 1
Share this question
or