Re: How to limit CWnd minimum size?
- From: Joseph M. Newcomer <newcomer@xxxxxxxxxxxx>
- Date: Fri, 01 Aug 2008 09:21:33 -0400
Take a look at my essay on limiting dialog box size on my MVP Tips site:
http://www.flounder.com/getminmaxinfo.htm
joe
On Thu, 31 Jul 2008 22:16:01 -0700, Landon <Landon@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote:
I use MFC Visual C++ 4.2.Joseph M. Newcomer [MVP]
I make a resizable Window. But I want to limit the minimum width and height
of the Window so that all the contents still displayed.
I have tried:
void CToiawaseDlg::OnSize(UINT nType, int cx, int cy)
{
CDialog::OnSize(nType, cx, cy);
// TODO: ?????????? ??????????????????
if( cx < MIN_MAINWND_WIDTH )
cx = MIN_MAINWND_WIDTH;
if( cy < MIN_MAINWND_HEIGHT )
cy = MIN_MAINWND_HEIGHT;
}
but it did not work, it still too small if I tried to resize it.
How to solve this?
Thank you.
email: newcomer@xxxxxxxxxxxx
Web: http://www.flounder.com
MVP Tips: http://www.flounder.com/mvp_tips.htm
.
- Prev by Date: Re: icon background is not transparent when aero is enabled in vis
- Next by Date: Re: How do I expose interfaces from an MFC application.
- Previous by thread: Re: How to limit CWnd minimum size?
- Next by thread: Re: SetClipBoard returns Junk characters!
- Index(es):
Relevant Pages
|