Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Docking Pane
  New Posts New Posts RSS Feed - [SOLVED] HOWTO: Custom pane layout
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

[SOLVED] HOWTO: Custom pane layout

 Post Reply Post Reply
Author
Message
mgampi View Drop Down
Senior Member
Senior Member
Avatar

Joined: 14 July 2003
Status: Offline
Points: 1172
Post Options Post Options   Thanks (0) Thanks(0)   Quote mgampi Quote  Post ReplyReply Direct Link To This Post Topic: [SOLVED] HOWTO: Custom pane layout
    Posted: 16 August 2011 at 7:51am
Hi;

I use below code to create 4 docking panes. Two of them are closed just after creation and the other two should be shown on startup. This is the first problem - the wrong panes are shown and I'm definitely not using a loaded pane manager layout.
CXTPDockingPane* pwndPane1 = paneManager_.CreatePane(IDR_PANE_BOOKKEEPING, CRect(0, 0, 400, 200), xtpPaneDockTop);

    pwndPane1->SetOptions(xtpPaneNoCaption|xtpPaneNoFloatable);
    pwndPane1->Close();

    CXTPDockingPane* pwndPane2 = paneManager_.CreatePane(IDR_PANE_ANALYSIS_DETAIL, CRect(0, 0,200, 250), xtpPaneDockRight);

    pwndPane2->SetOptions(xtpPaneNoCaption|xtpPaneNoFloatable);
    pwndPane2->Close();


    CXTPDockingPane* pwndPane3 = paneManager_.CreatePane(IDR_PANE_OPTION_TREE, CRect(0, 0, 200, 120), xtpPaneDockLeft);
    CXTPDockingPane* pwndPane4 = paneManager_.CreatePane(IDR_PANE_TAGLIST, CRect(0, 0, 250, 250), xtpPaneDockRight);

Whenever the user executes a special command, the first two panes are hidden and the initially closed panes are shown. This works, but the layout of the panes is wrong. As soon as I set the options xtpPaneNoCaption|xtpPaneNoFloatable I'm unable to programmatically achieve a layout as shown by the red rectangles in the screenshot below:



How do I have to change my code to get the desired result?
Martin

Product: Xtreme Toolkit v 19.0.0, new Projects v 19.1.0
Platform: Windows 10 v 1909 (64bit)
Language: VC++ 2017
Back to Top
mgampi View Drop Down
Senior Member
Senior Member
Avatar

Joined: 14 July 2003
Status: Offline
Points: 1172
Post Options Post Options   Thanks (0) Thanks(0)   Quote mgampi Quote  Post ReplyReply Direct Link To This Post Posted: 16 August 2011 at 8:11am
Hi;

My mistake! I used to call SetMinTrackSize() / SetMaxTrackSize() and assigned std::numeric_limits<unsigned long>::max() to the x component of max track size. This leads to weird results inside the toolkit code...
Martin

Product: Xtreme Toolkit v 19.0.0, new Projects v 19.1.0
Platform: Windows 10 v 1909 (64bit)
Language: VC++ 2017
Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 12.04
Copyright ©2001-2021 Web Wiz Ltd.

This page was generated in 0.063 seconds.