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

Update RelativeSize when user drags splitter

1 Answer 38 Views
Docking
This is a migrated thread and some comments may be shown as answers.
Jason
Top achievements
Rank 1
Jason asked on 15 Aug 2013, 06:32 PM
I have 2 SplitContainers in another one which is all loaded from an XML file using my own deserialization code similar to LoadLayout. Regardless of whether I use ProportionalStackPanel.SetRelativeSize during my load or let it use the defaults, when I later attempt to serialize it, the ProportionalStackPanel.GetRelativeSize function returns the original values that it was loaded with. I would expect that when a user drags the splitter bar that the RelativeSizeProperty would update so that when I use the get function it returns the current values. The same applies for figuring out the RelativeSize for PaneGroups within a SplitContainer.

Is there something I am missing or am I going to have to manually recalculate the split ratio based on the RenderSize to Parent.RenderSize or something similar? If that is the case, would there be an alternative such as handling an event when the split bar moves?

1 Answer, 1 is accepted

Sort by
0
Pana
Telerik team
answered on 20 Aug 2013, 06:23 PM
Hello,

I would like to recommend you to use the Save and Load Layout methods of the RadDocking. It seems you have already considered and rejected it so in your case it seems the LayoutChangeEnded event of the RadDocking may help. There you can try to recalculate the relative sizes. Currently there is no public API that may help you further.

Regards,
Pana
Telerik
TRY TELERIK'S NEWEST PRODUCT - EQATEC APPLICATION ANALYTICS for WPF.
Learn what features your users use (or don't use) in your application. Know your audience. Target it better. Develop wisely.
Sign up for Free application insights >>
Tags
Docking
Asked by
Jason
Top achievements
Rank 1
Answers by
Pana
Telerik team
Share this question
or