RePaint area (region) in sdi view MFC
I want to ask you one question about SDI MFC application. How can I repaint some area (region) on the view in SDI MFC application but without repaint complete v开发者_运维问答iew?
Use ::InvalidateRect() and/or CWnd::InvalidateRect().
Have a look at the Invalidate functionality. You can invalidate a rectangle, a region or the while window.
An invalidated region will be repainted with the next WM_PAINT message. In your OnPaint() method you can query the clipping region from the CDC object. If the object in question is not withing the region/rectangle, you can skip drawing it.
精彩评论