The MASM Forum

General => The Campus => Topic started by: xandaz on November 06, 2020, 05:17:24 AM

Title: mdi children strob when resizing. why?
Post by: xandaz on November 06, 2020, 05:17:24 AM
i'm having problems with the mdi children of and app i'm working on. is there some style i should include somewhere? thanks in advance. I'm not be an ass am i?
Title: Re: mdi children strob when resizing. why?
Post by: xandaz on November 06, 2020, 05:19:00 AM
   I would also like to know of there is another message other than WS_SIZE when a window is MAXIMIZED. not too much to ask i hope.
Title: Re: mdi children strob when resizing. why?
Post by: Greenhorn on November 06, 2020, 05:54:25 AM
Is this helping you ? Tutorial 32: Multiple Document Interface (MDI) (http://www.interq.or.jp/chubu/r6/masm32/tute/tute032.html)
Title: Re: mdi children strob when resizing. why?
Post by: xandaz on November 06, 2020, 06:47:56 AM
   thanks greenhorn. i'm checking it out.
Title: Re: mdi children strob when resizing. why?
Post by: xandaz on November 06, 2020, 07:08:21 AM
    I'm not sure that the changes made make much difference. Child windows are still strobing when resized. Thanks anyway. :thumbsup:
Title: Re: mdi children strob when resizing. why?
Post by: Adamanteus on November 06, 2020, 09:21:15 AM
 Maybe, need double buffering when painting ...
Title: Re: mdi children strob when resizing. why?
Post by: hutch-- on November 06, 2020, 11:59:44 AM
Set the parent window colour to 0 (transparent). You get the flickering due to double repaints.
Title: Re: mdi children strob when resizing. why?
Post by: xandaz on November 07, 2020, 05:10:33 AM
   Thanks ppls. :thumbsup:
Title: Re: mdi children strob when resizing. why?
Post by: xandaz on November 07, 2020, 05:22:39 AM
  Nah....it's still strobing. Thanks anyway. Double buffering? how do i do that? :thumbsup:
Title: Re: mdi children strob when resizing. why?
Post by: Adamanteus on November 07, 2020, 06:52:47 AM
 In this topic is example (http://masm32.com/board/index.php?topic=8804.0).
Title: Re: mdi children strob when resizing. why?
Post by: hutch-- on November 07, 2020, 09:50:55 AM
What is the WNDCLASSEX style set to ?

If you are using => CS_HREDRAW or CS_VREDRAW

Change it to

CS_BYTEALIGNCLIENT or CS_BYTEALIGNWINDOW

Title: Re: mdi children strob when resizing. why?
Post by: Adamanteus on November 07, 2020, 10:26:34 PM
 By my experiance WNDCLASSEX - better for small controls, as buttons, for resizeable windows better WNDCLASS - as more options by silence, will work more sure win GDI of differ OS versions.
Title: Re: mdi children strob when resizing. why?
Post by: xandaz on November 08, 2020, 06:46:31 AM
    Thanks Hutch, ty guys. worked like a charm.  :thumbsup:
Title: Re: mdi children strob when resizing. why?
Post by: jj2007 on November 08, 2020, 08:28:05 AM
Quote from: Adamanteus on November 07, 2020, 10:26:34 PM
By my experiance WNDCLASSEX - better for small controls, as buttons, for resizeable windows better WNDCLASS - as more options by silence, will work more sure win GDI of differ OS versions.

I made a test with a "difficult" window that has a lot of flicker, and could not see any difference (on Win7-64) :cool:
Title: Re: mdi children strob when resizing. why?
Post by: Adamanteus on November 09, 2020, 04:12:21 AM
 As is it's not seenable difference  :hmmm:
Title: Re: mdi children strob when resizing. why?
Post by: hutch-- on November 09, 2020, 11:02:33 AM
WNDCLASS is just a macro for WNDCLASSEX, WNDCLASS was used in Win16 and it has been maintained via the macro for backwards compatibility.
Title: Re: mdi children strob when resizing. why?
Post by: jj2007 on November 09, 2020, 10:12:24 PM
A macro?

WNDCLASSA STRUCT
  style             DWORD      ?
  lpfnWndProc       DWORD      ?
  cbClsExtra        DWORD      ?
  cbWndExtra        DWORD      ?
  hInstance         DWORD      ?
  hIcon             DWORD      ?
  hCursor           DWORD      ?
  hbrBackground     DWORD      ?
  lpszMenuName      DWORD      ?
  lpszClassName     DWORD      ?
WNDCLASSA ENDS
...
WNDCLASS  equ  <WNDCLASSA>
Title: Re: mdi children strob when resizing. why?
Post by: hutch-- on November 13, 2020, 10:59:10 AM
Yerp,

But not a MASM macro, its built into the DLL that provides WNDCLASSEX.