Print Page | Close Window

How can I change the pane’s size

Printed From: Codejock Forums
Category: Codejock Products
Forum Name: Docking Pane
Forum Description: Topics Related to Codejock Docking Pane
URL: http://forum.codejock.com/forum_posts.asp?TID=1934
Printed Date: 28 April 2024 at 7:20pm
Software Version: Web Wiz Forums 12.04 - http://www.webwizforums.com


Topic: How can I change the pane’s size
Posted By: 9rap
Subject: How can I change the pane’s size
Date Posted: 08 March 2005 at 1:19am

How can I change the pane's size after it has created.




Replies:
Posted By: gshawn
Date Posted: 08 March 2005 at 2:19am

I don't know anything about C++, but this could be a possible way to do it in the ActiveX version... should translate easily to the C++ version. Basically, save the values of the pane's min/max tracksizes into variables, then set both min and max tracksizes to the size you want to resize the pane to (300x200 pixels here), then restore the min/max tracksize properties. It's an ungly hack, and as far as I know it would only work with undocked panes...

    MinWidth = DockingPaneManager.Panes(i).MinTrackSize.Width
    MinHeight = DockingPaneManager.Panes(i).MinTrackSize.Height
    MaxWidth = DockingPaneManager.Panes(i).MaxTrackSize.Width
    MaxHeight = DockingPaneManager.Panes(i).MaxTrackSize.Height

    DockingPaneManager.Panes(i).MinTrackSize.SetSize 300, 200
    DockingPaneManager.Panes(i).MaxTrackSize.SetSize 300, 200
    DockingPaneManager.RecalcLayout

    DockingPaneManager.Panes(i).MinTrackSize.SetSize MinWidth, MinHeight
    DockingPaneManager.Panes(i).MaxTrackSize.SetSize MaxWidth, MaxHeight
    DockingPaneManager.RecalcLayout




Print Page | Close Window

Forum Software by Web Wiz Forums® version 12.04 - http://www.webwizforums.com
Copyright ©2001-2021 Web Wiz Ltd. - https://www.webwiz.net