Can I force a parent window to redraw without causing its children to redraw?
Is it possible to invalidate a window without invalidating its children? (display invalidation to cause a repaint of the parent window, but not redraw its children)
This assumes that the parent window already has the "clipchildren" style, so that its painting wouldn't inh开发者_如何学编程erently invalidate the children.
InvalidateRect() already does this. Another way is RedrawWindow() with the RDW_NOCHILDREN option.
Parent windows are always going to redraw any child windows that intersect with the window's update region.
So, really, to get the behaviour you want, when invalidating the parent window - exclude the child rects from the region you pass to InvalidateRegion.
精彩评论