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

Freeze layout to prevent resizing

1 Answer 103 Views
Docking
This is a migrated thread and some comments may be shown as answers.
Pete
Top achievements
Rank 1
Pete asked on 15 Aug 2011, 04:26 PM
The following article describes how freeze docked panels
http://www.telerik.com/help/silverlight/raddocking-how-to-freeze-the-layout.html

"Disable Resizing of the Panes

In order to disable the pane resizing, you need to use the MinWidth, MinHeight, MaxWidth and MaxHeight properties of the RadSplitContainer."

How is this achieved? The ActualWidth/ActualHeight, DesiredSize and RenderSize properties are either zero or the incorrect sizes. I cannot find any suitable properties I can use and also I do not understand why this would freeze the sizes of the panes that are contained in the RadSplitContainer

Thanks

1 Answer, 1 is accepted

Sort by
0
Pana
Telerik team
answered on 19 Aug 2011, 08:15 AM
Hi,

 The approach described in this article requires you to set concrete sizes in pixels to the MinWidth/Height and MaxWidth/Height properties so using the DesiredSize, ActualWidth/Height, RenderSize may not help you to resolve this problem. Another approach of freezing the SplitContainer resizing is to either remove or disable the Resizer controls for the SplitContainer and PaneGroup templates.

For example the following code will disable the RadGridResizers in the RadDocking:

<UserControl x:Class="RadDocking.MainPage"
        mc:Ignorable="d"
        d:DesignHeight="300" d:DesignWidth="400">
  
    <Grid x:Name="LayoutRoot" Background="White">
        <telerik:RadDocking>
            <telerik:RadDocking.Resources>
                <Style TargetType="telerik:RadGridResizer">
                    <Setter Property="IsHitTestVisible" Value="False" />
                </Style>
            </telerik:RadDocking.Resources>
            <telerik:RadSplitContainer Orientation="Vertical">
                <telerik:RadSplitContainer>
                    <telerik:RadPaneGroup>
                        <telerik:RadPane />
                        <telerik:RadPane />
                    </telerik:RadPaneGroup>
                    <telerik:RadPaneGroup>
                        <telerik:RadPane />
                        <telerik:RadPane />
                    </telerik:RadPaneGroup>
                </telerik:RadSplitContainer>
                <telerik:RadSplitContainer>
                    <telerik:RadPaneGroup>
                        <telerik:RadPane />
                        <telerik:RadPane />
                    </telerik:RadPaneGroup>
                    <telerik:RadPaneGroup>
                        <telerik:RadPane />
                        <telerik:RadPane />
                    </telerik:RadPaneGroup>
                </telerik:RadSplitContainer>
            </telerik:RadSplitContainer>
        </telerik:RadDocking>
    </Grid>
</UserControl>

 
All the best,
Pana
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get now >>
Tags
Docking
Asked by
Pete
Top achievements
Rank 1
Answers by
Pana
Telerik team
Share this question
or