Codejock Forums Homepage
Forum Home Forum Home > Codejock Products > Visual C++ MFC > Command Bars
  New Posts New Posts RSS Feed - Toolbar custom position
  FAQ FAQ  Forum Search   Events   Register Register  Login Login

Toolbar custom position

 Post Reply Post Reply
Author
Message
Red Devil View Drop Down
Newbie
Newbie


Joined: 15 March 2006
Location: Zimbabwe
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote Red Devil Quote  Post ReplyReply Direct Link To This Post Topic: Toolbar custom position
    Posted: 17 March 2006 at 7:51am
Init toolbar allows standart positions top, left, rigth, bottom, etc. I desire place one toolbar in right corner, and another toolbar in left corner. Screenshot is show how i desire place the toolbars.

CToolBarInfo may help me ? I not find info about this class in help.

Image

Back to Top
Red Devil View Drop Down
Newbie
Newbie


Joined: 15 March 2006
Location: Zimbabwe
Status: Offline
Points: 5
Post Options Post Options   Thanks (0) Thanks(0)   Quote Red Devil Quote  Post ReplyReply Direct Link To This Post Posted: 18 March 2006 at 7:51am
I solve a problem. I do :
OnCreate() {
...
    RepositionBars(AFX_IDW_CONTROLBAR_FIRST, AFX_IDW_CONTROLBAR_LAST, AFX_IDW_PANE_FIRST);
    CXTPWindowRect rect(pLBar);
    CRect rcRect;
    GetClientRect(rcRect);
    if (IsVerticalPosition(pLeftBar->GetPosition())) rect.OffsetRect(0, rect.Height());
        else rect.OffsetRect(rect.Width() + rcRect.right, 0);
    GetCommandBars()->DockCommandBar(pRightBar, rect, pLeftBar->GetDockBar());
...
}
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.125 seconds.