GetClipBox

Syntax

int GetClipBox(hDC,lpRect)

This function retrieves the dimensions of the tightest bounding rectangle around the current clipping boundary. The dimensions are copied to the buffer pointed to by the lpRect parameter.

Parameter Type/Description  

hDC HDC Identifies the device context.  
lpRect LPRECT Points to the RECT data structure that is to receive the rectangle dimensions.  

Return Value

The return value specifies the clipping region's type. It can be any one of the following values:

Value Meaning  

COMPLEXREGION Clipping region has overlapping borders.  
ERROR Device context is not valid.  
NULLREGION Clipping region is empty.  
SIMPLEREGION Clipping region has no overlapping borders.