Dock CXTPToolBar at bottom of CMDIChildWn |
Post Reply |
Author | |
CamG
Newbie Joined: 28 February 2004 Status: Offline Points: 4 |
Post Options
Thanks(0)
Posted: 28 February 2004 at 9:09pm |
Scenario: MDI application, want to dock toolbar at bottom of child window. CChildFrame is derived from CMDIChildWnd, and m_wndToolBar is a CXTPToolBar. Code below results in toolbar docked at top - anyone with any ideas as to why? I even threw in a call to RepositionBars() for good measure.
int CChildFrame::OnCreate(LPCREATESTRUCT lpCreateStruct){
} Edited by CamG |
|
SuperMario
Admin Group Joined: 14 February 2004 Status: Offline Points: 18057 |
Post Options
Thanks(0)
|
Are you looking to have one toolbar that is docked at the bottom of the
main MDI form that will be under the child window? Or do you want
a separate toolbar for each child window that is docked to the bottom
of each window?
|
|
CamG
Newbie Joined: 28 February 2004 Status: Offline Points: 4 |
Post Options
Thanks(0)
|
One separate toolbar per child window, docked and fixed (no grab handle, customisation, etc.). I have several doc views, and the view loaded into the child window will set the toolbar's configuration (i.e. selects which toolbar resource is loaded). |
|
CamG
Newbie Joined: 28 February 2004 Status: Offline Points: 4 |
Post Options
Thanks(0)
|
Came up with another approach which gives better results, but not quite right yet... int CChildFrame::OnCreate(LPCREATESTRUCT lpCreateStruct) CXTPCommandBars* pCommandBars = CXTPCommandBars::CreateCommandBars(); pCommandBars->GetCommandBarsOptions()->bSyncFloa tingBars = TRUE; // Create ToolBar if (!pToolBar || !pToolBar->LoadToolBar(IDR_CHILDFRAME)) pToolBar->ModifyStyle(CBRS_GRIPPER, 0); The toolbar is now a proper child of the MDIChildWnd and is docked bottom, but hiding the gripper and customise toolbar button is proving to be problematic. The call to pToolBar->ModifyStyle(CBRS_GRIPPER, 0) has no effect.
|
|
Oleg
Admin Group Joined: 21 May 2003 Location: United States Status: Offline Points: 11234 |
Post Options
Thanks(0)
|
call ModifyBarStyle instead ModifyStyle. set XTP_COMMANDBARS_OPTIONS::bShowExpandButtonAlways = FALSE |
|
Oleg, Support Team
CODEJOCK SOFTWARE SOLUTIONS |
|
Post Reply | |
Tweet
|
Forum Jump | Forum Permissions You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum |