DragDockPanel - Re-size minimized panels?

Aug 14, 2013 at 9:10 AM
Edited Aug 14, 2013 at 9:11 AM
Hi Guys,

This is a big ask so thank you very much if you can provide any help.

Is it possible to change the size of a minimized panels (just at design time, not by the user)?

When the Silverlight application is running and I minimize a panel I get the header of the minimized panel (looks good!) and also some of the content of the panel still appearing. It is this small section of the content panel I'd like to either make height zero/make collapsed and only show the header of the minimized panel.

I have the panels minimizing to the top and I'd like the main maximized panel to use more of the grid space where the minimized panels are not using (due to them not showing some of the content under their headers).

I know I can change the look of the Panels by changing the <Style TargetType="local:DragDockPanel"> section.

Can I add code to the '<Style TargetType="local:DragDockPanelHost">' section to alter the size of minimized panels perhaps. Or is there another way to change how the panels minimize.

Many thanks, Thomas
Aug 14, 2013 at 1:13 PM
Edited Aug 14, 2013 at 1:14 PM
I actually solver my problem :)

(1)
I rebuilt the Blacklight dll from the Source Code I downloaded from here but changed:
From:
    public class DragDockPanelHost : ItemsControl
    ..
    /// <summary>
    /// Stores the minimized row height.
    /// </summary>
    private double minimizedRowHeight = 75;
To:
    public class DragDockPanelHost : ItemsControl
    ..
    /// <summary>
    /// Stores the minimized row height.
    /// </summary>
    private double minimizedRowHeight = 40;

You can also do the same as above but setting it in your calling application by using
<yourPannelHostObject>.MinimizedRowHeight = 40;

(2)
Also In my appSyles.config I changed the Margin from "4" to "2" to reduce the space between the panels.
    <local:OuterGlowBorder 
            OuterGlowOpacity="0.4" OuterGlowSize="7"
            CornerRadius="3,3,3,3" 
            Margin="2"