Advertisement

MFC Question

Started by July 28, 2000 05:26 AM
0 comments, last by Blah2 24 years, 4 months ago
How do I calculate the area of a CMDIFrameWnd''s client rect which is not covered by toolbars, status bars, etc.? What I want to do is create 4 child windows in a CMDIFrameWnd which each have equal size, but if I use GetClientRect() to calculate the size of the space I''m dividing into fourths, my toolbars cover part of the child windows. What''s the easiest way to determine the area of a client rect which is not covered by control bars? Thanks in advance for any help! ----Blah
Ignore the frame window, use the client rect from your CViewDerivitive. The CView is not covered by toolbars.

You say you want four child windows? Try using a "static" splitter. The MFC App Wizard can give you a "dynamic" splitter. You have to read the MSDN docs to see exactly how to use a static splitter, but the CFrameWndDerivative creates the Splitter, tells it how many panes to have(rows and cols) then adds the CViews to each pane in the splitter.

This topic is closed to new replies.

Advertisement