int GetUpdateRgn(hwnd, hrgn, fErase) | |||||
HWND hwnd; | /* handle of window, */ | ||||
HRGN hrgn; | /* handle of region, */ | ||||
BOOL fErase; | /* erase flag | */ |
The GetUpdateRgn function retrieves the update region of a window. The coordinates of the update region are relative to the upper-left corner of the window (that is, they are client coordinates).
hwnd
Identifies the window whose update region is to be retrieved.
hrgn
Identifies the update region.
fErase
Specifies whether the window background should be erased and whether nonclient areas of child windows should be drawn. If this parameter is FALSE, no drawing is done.
The return value is SIMPLEREGION (region has no overlapping borders), COMPLEXREGION (region has overlapping borders), or NULLREGION (region is empty), if the function is successful. Otherwise, the return value is ERROR.
The BeginPaint function automatically validates the update region, so any call to the GetUpdateRgn function made immediately after the call to BeginPaint retrieves an empty update region.
BeginPaint, GetUpdateRect, InvalidateRgn, UpdateWindow, ValidateRgn