CWnd::CalcWindowRect 

virtual void CalcWindowRect( LPRECT lpClientRect, UINT nAdjustType = adjustBorder );

Parameters

lpClientRect

Points to a RECT structure or CRect object that contains the resultant value of the window rectangle.

nAdjustType

An enumerated type used for in-place editing. It can have the following values: CWnd::adjustBorder = 0, which means that scroll-bar sizes are ignored in calculation; and CWnd::adjustOutside = 1, which means that they are added into the final measurements of the rectangle.

Remarks

Call this member function to compute the required size of the window rectangle based on the desired client-rectangle size. The resulting window rectangle (contained in lpClientRect) can then be passed to the Create member function to create a window whose client area is the desired size.

Called by the framework to size windows prior to creation.

A client rectangle is the smallest rectangle that completely encloses a client area. A window rectangle is the smallest rectangle that completely encloses the window.

CWnd OverviewClass MembersHierarchy Chart

See Also   ::AdjustWindowRectEx