NAME
XRectInRegion — determine if a rectangle resides in a region.
SYNOPSIS
int XRectInRegion(r, x, y, width, height) Region r; int x, y; unsigned int width, height;
ARGUMENTS
rSpecifies the region.
x
ySpecify the x and y coordinates of the upper-left corner of the rectangle, relative to the region’s origin.
width
heightSpecify the width and height in pixels of the rectangle.
RETURNS
RectangleIn, RectangleOut, or RectanglePart.
DESCRIPTION
XRectInRegion() returns RectangleIn if the rectangle is completely contained in the region r, RectangleOut if it is completely outside, and RectanglePart if it is partially inside.
Regions are located using an offset from a point (the region origin) which is common to all regions. It is up to the application to interpret the location of the region relative to a drawable. If the region is to be used as a clip_mask by calling XSetRegion(), the upper-left corner of region relative to the drawable used in the graphics request will be at (xoffset + clip_x_origin, yoffset + clip_y_origin), where xoffset and yoffset are the offset of the region and clip_x_origin and clip_y_origin are the clip origin in the GC used.
For this function, the x and y arguments are interpreted relative to the region origin; no drawable is involved.
STRUCTURES
Region is a pointer to an opaque structure type.
SEE ALSO
XClipBox(), XCreateRegion(), XDestroyRegion(), XEmptyRegion(), XEqualRegion(), XIntersectRegion(), XOffsetRegion(), XPointInRegion(), XPolygonRegion(), XSetRegion(), XShrinkRegion(), XSubtractRegion(), XUnionRectWithRegion(), XUnionRegion(), XXorRegion().
Xlib Reference Manual