Thread View: comp.os.ms-windows.programmer.misc
3 messages
3 total messages
Started by Dominic Pok Man Tam
Thu, 21 Jan 1993 09:04
ToolBar under MDI application
Author: Dominic Pok Man Tam
Date: Thu, 21 Jan 1993 09:04
Date: Thu, 21 Jan 1993 09:04
7 lines
806 bytes
806 bytes
I have a toolbar implemented in my MDI application. However, my child windows
will ovelap the toolbar. Can anyone tell me how to resize the MDI client
windows so that it will not ovelapped with the toolbar. The MDI frame window is
the parent of both the toolbar window and the MDI client window!!
e-mail or post to newsgroup is welcome!!
Re: ToolBar under MDI application
Author: Chris Marriott
Date: Thu, 21 Jan 1993 19:12
Date: Thu, 21 Jan 1993 19:12
28 lines
1784 bytes
1784 bytes
In article <dtam.727607040@sfu.ca> dtam@fraser.sfu.ca writes: >I have a toolbar implemented in my MDI application. However, my child windows >will ovelap the toolbar. Can anyone tell me how to resize the MDI client >windows so that it will not ovelapped with the toolbar. The MDI frame window is >the parent of both the toolbar window and the MDI client window!! > >e-mail or post to newsgroup is welcome!! > > The answer is to have the Toolbar window as a child of the FRAME window, not of the MDI client. All you have to do then is process the WM_SIZE message in the frame window proc, and resize/move the MDI client window yourself, rather than passing WM_SIZE on to DefFrameProc, which resizes the MDI client to fill the client area of the frame window. Best wishes, Chris -- -------------------------------------------------------------------------- | Chris Marriott | chris@chrism.demon.co.uk | | Warrington, UK | BIX: cmarriott | | | CIX: cmarriott | | Save the whales. Collect the whole set. | CompuServe: 100113,1140 | --------------------------------------------------------------------------
Re: ToolBar under MDI application
Author: Baruch Nissenbaum
Date: Sat, 23 Jan 1993 20:31
Date: Sat, 23 Jan 1993 20:31
27 lines
1832 bytes
1832 bytes
In article <727643543snz@chrism.demon.co.uk> chris@chrism.demon.co.uk writes:
>In article <dtam.727607040@sfu.ca> dtam@fraser.sfu.ca writes:
>
>>I have a toolbar implemented in my MDI application. However, my child windows
>>will ovelap the toolbar. Can anyone tell me how to resize the MDI client
>>windows so that it will not ovelapped with the toolbar. The MDI frame window is
>>the parent of both the toolbar window and the MDI client window!!
>>
>
>The answer is to have the Toolbar window as a child of the FRAME window,
>not of the MDI client. All you have to do then is process the WM_SIZE
>message in the frame window proc, and resize/move the MDI client window
>yourself, rather than passing WM_SIZE on to DefFrameProc, which resizes
>the MDI client to fill the client area of the frame window.
>
1. Making a window be a son of the MDI frame is not trivial in OWL..
I found two ways to do this:
a. Create the child window with a null parent, then call SetParent
to set the parent be the MDI window. (not touching the child).
b. In the constructor of toolbar call SetFlags( WB_MDICHILD, 0).
2. All child windows that process WM_SIZE must also call the default WM_SIZE
method to make the MDI work correctly.
Good luck ! (you'll need much if your working in MSwindows..)
Baruch
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads