ExcludeUpdateRgn function

The ExcludeUpdateRgn function prevents drawing within invalid areas of a window by excluding an updated region in the window from a clipping region.

Syntax

int ExcludeUpdateRgn(
  HDC  hDC,
  HWND hWnd
);

Parameters

hDC

Handle to the device context associated with the clipping region.

hWnd

Handle to the window to update.

Return Value

The return value specifies the complexity of the excluded region; it can be any one of the following values.

Value Meaning
COMPLEXREGION Region consists of more than one rectangle.
ERROR An error occurred.
NULLREGION Region is empty.
SIMPLEREGION Region is a single rectangle.

Requirements

   
Windows version Windows 2000 Professional [desktop apps only] Windows 2000 Server [desktop apps only]
Target Platform Windows
Header winuser.h (include Windows.h)
Library User32.lib
DLL User32.dll

See Also

BeginPaint

GetUpdateRect

GetUpdateRgn

Painting and Drawing Functions

Painting and Drawing Overview

UpdateWindow