title: Behavior of WS_CLIPCHILDREN and InvalidateRect in Windows 7
body: <p>To reduce flickering I create my parent windows using the WS_CLIPCHILDREN flag and I call InvalidateRect during the WM_SIZE event. This approach has worked well in Windows XP. However, I recently started programming on Windows 7 and I'm now experiencing rendering issues when resizing windows. When resizing a window its contents is not refreshed until I do something that forces a redraw, like minimizing and restoring the window.</p>
  
  <p>I've tried following up the InvalidateRect with a UpdateWindow call but with no effect.</p>
  
  <p>Does anyone know how to do it correctly?</p>
  
  <p><b>Update</b><br>
  I found a workaround: calling <code>InvalidateRect(childHWND, NULL, FALSE)</code>
  on all child windows followed by a <code>InvalidateRect(parentHWND, NULL, TRUE)</code> on the parent window fixes the rendering problem without introducing noticeable flickering.</p>
  
  <p>Other suggestions are still welcome!</p>
  
  <p><b>Update 2</b><br>
  I tried the <code>RedrawWindow(hwnd, 0, 0, RDW_INVALIDATE | RDW_ALLCHILDREN)</code> but that resulted in some rendering issues (left-over pixels).</p>
  
  <p><b>Update 3</b><br>
  The RedrawWindow works when followed by a <code>InvalidateRect(hwnd, NULL, TRUE)</code>. Thanks @interjay!</p>