Newsgroups: comp.windows.ms.programmer Path: utzoo!utgpu!watserv1!sunee!gpsteffl From: gpsteffl@sunee.waterloo.edu (Glenn Patrick Steffler) Subject: Re: Preventing Windows from resizing windows Message-ID: <1991Feb7.190951.7723@sunee.waterloo.edu> Organization: Gerbils On Speed Inc. References: <16477.27ade4f3@ul.ie> Date: Thu, 7 Feb 91 19:09:51 GMT Lines: 41 In article <16477.27ade4f3@ul.ie> oreillyj@ul.ie writes: >I am using the MSC windows SDK. Is there any way of preventing Windows >from resizing the size of a particular application's window in response >to a resize request. My first question is...why not declare the window without the WS_THICKFRAME parameter. Else, if you really want to get down and dirty... WM_SYSCOMMAND, SC_MOVE | SC_SIZE These messages are sent just before the window is about to be movedor sized. You can do all sorts or nasty things here, like returning with some valid return value (see samples/defprocs/defwnd.c for more info on how windows processes the message). I myself would disable the thickframe style, and avoid messyness. > I would also be interested to know what exactly >setting a window's style to CS_SAVEBITS does. It's supposed to save >the portion of the screen that is covered by another window and restore >that portion when the window becomes active again. Alas, this does not >seem to happen... I would think your application would know better how to manage the client updating better than windows. i.e. keep a bitmap around for yourself, and make it discardable, so in low memory situations, the bitmap will disappear, but you could re-create it in such a case. This is basically what windows does with the CS_SAVEBITS...notice the mention that it MAY NOT ALWAYS SAVE the BITS in low memory situations. > >thanks in advance > >John O'Reilly, >oreillyj@ul.ie -- Co-Op Scum "Bo doesn't know software" - George Brett "The galaxial hearth steams the sea as the sky blood red embrasses darkness" -John Constantine (HellBlazer) Glenn Steffler