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

panels does not get resized with the Main framework windows on window restore

3 Answers 208 Views
Docking
This is a migrated thread and some comments may be shown as answers.
Jawad
Top achievements
Rank 1
Jawad asked on 09 Jul 2013, 11:21 AM

Hi,
We are using Telerik RadDocking control within our main framework window. The RadDocking contains two RadSplitContainers and each container has a RadPaneGroup with one Rad panel to Display Data. The Application is created using Prism with MEF Container using MVVM design Pattern.

Description:

The left Container is Docked Permanently so that it cannon float/Auto hide/Close. This container is set to a minimum Width and Height. As there is no Maximum Width this container is able to fill in available space in the Main Framework Window (e.g. when the panel in the right container is undocked to float the left container takes all the framework window).
The Right Container is able to Float/Auto Hide/Close. This Container is also set to a minimum Width and Height.

Issue 1:

with the Main framework window on full screen if the right Container is moved to the extreme right to its minimum Width and the main framework window is restored/resized the containers doesn't get resize to the main framework window.  This causes the Right docked container and some portion of left docked container to be dragged out of the main framework window and is not visible. To make the right container visible either i need to resize the main framework window to a bigger size or maximise the Main framework window to full screen. The screenshot and an example code snippet is given below. 

Is there a way to resize the container according to the main framework windows size?  so that both the containers with panel are visible in any scenario whether right docked container is moved to extreme right to its minimum width or left docked container is moved to extreme left to it minimum width.
I have tried the proportional stack panel with relative width set to both containers but it gives the same issue as above. 


Thanks,

<telerik:RadDocking x:Name="SiteHomeDockingControl" Grid.Column="0" Grid.ColumnSpan="3" Grid.Row="1" HasDocumentHost="False" 
                    PreviewShowCompass="SiteHomeDockingControl_PreviewShowCompass"  >
  
                <telerik:RadSplitContainer telerik:RadDocking.SerializationTag="RadSplitContainerSites" BorderThickness="0"  
                MinWidth="305" MinHeight="305"  telerik:DockingPanel.InitialSize="1000,500">
                    <telerik:RadPaneGroup x:Name="RadPaneGroupSites" telerik:RadDocking.SerializationTag="RadPaneGroupSites" BorderThickness="0">
                        <telerik:RadPane PaneHeaderVisibility="Collapsed" CanUserClose="False" CanFloat="False" CanUserPin="False" 
                                             telerik:RadDocking.SerializationTag="RadPaneSites" >
                            <ScrollViewer HorizontalScrollBarVisibility="Disabled" VerticalScrollBarVisibility="Auto">
                                <Grid VerticalAlignment="Stretch" HorizontalAlignment="Stretch" Margin="35,15,15,15">
                                <TextBlock Text="Just an example Docked Pane 1."/>
                                </Grid>
                            </ScrollViewer>
                        </telerik:RadPane>
                    </telerik:RadPaneGroup>
                </telerik:RadSplitContainer>
  
                <telerik:RadSplitContainer InitialPosition="DockedRight" telerik:RadDocking.SerializationTag="RadSplitContainerPlantHierarchies"
                MinWidth="305" MinHeight="305" telerik:DockingPanel.InitialSize="400,500">
                    <telerik:RadPaneGroup telerik:RadDocking.SerializationTag="RadPaneGroupPlantHierarchies">
                        <telerik:RadPane telerik:RadDocking.SerializationTag="RadPanePlantHierarchies" Header="Plant Hierarchies"
                        IsHidden="{Binding DataContext.HidePlantHierarchies, ElementName=SiteHomeDockingControl, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}">
                            <Grid>
                            <TextBlock Text="Just an example Docked Pane 2."/>
                            </Grid>
                        </telerik:RadPane>
                    </telerik:RadPaneGroup>
                </telerik:RadSplitContainer>
  
</telerik:RadDocking>

3 Answers, 1 is accepted

Sort by
0
Ventzi
Telerik team
answered on 15 Jul 2013, 11:37 AM
Hi,

In the current version of RadDocking it is not possible to set both the MinWidth and relative sizes to the Panes of the control. The approach with which you can achieve the closes to this behavior is:
  • Place the two RadSplitContainer in one parent RadSplitContainer.
  • Set the telerik:ProportionalStackPanel.RelativeSize of the two inner containers.
  • Set the MinWidth of the first RadSplitContainer to for example 305
  • Finally set the MinWidth/MinHeight of the MainWindow

I created and attached a sample project for you with the described approach, hope this is helpful.


Regards,
Ventzi
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 >>
0
Jawad
Top achievements
Rank 1
answered on 22 Jul 2013, 02:32 PM
Hi i have tried your approach but when i restored the main framework window after dragging one pane to its minimum width, both the panes overlapped each other into a blank area in the middle of both panes. if i can solve this it will be great. 

Thanks, 
0
Vladi
Telerik team
answered on 23 Jul 2013, 10:25 AM
Hello Jawad,

As mentioned before setting both the MinWidth and relative sizes to the Panes of the control is not possible and may lead to some unexpected behavior. Could you describe to us the exact issue you are experiencing and the steps needed for reproducing it. A screenshot of the issue would be very helpful.

Regards,
Vladi
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
Jawad
Top achievements
Rank 1
Answers by
Ventzi
Telerik team
Jawad
Top achievements
Rank 1
Vladi
Telerik team
Share this question
or