NAME
XCopyPlane − copy a single plane of a drawable into a drawable with depth, applying pixel values.
Synopsis
XCopyPlane(display, src, dest, gc, src_x, src_y, width,
height, dest_x, dest_y, plane)
Display *display;
Drawable src, dest;
GC gc;
int src_x, src_y;
unsigned int width, height;
int dest_x, dest_y;
unsigned long plane;
Arguments
displaySpecifies a connection to an X server; returned from XOpenDisplay().
src
destSpecify the source and destination drawables.
gcSpecifies the graphics context.
src_x
src_ySpecify the x and y coordinates of the upper-left corner of the source rectangle relative to the origin of the drawable.
width
heightSpecify the width and height in pixels. These are the dimensions of both the source and destination rectangles.
dest_x
dest_ySpecify the x and y coordinates at which the copied area will be placed relative to the origin of the destination drawable.
planeSpecifies the source bit-plane. You must set exactly one bit, and the bit must specify a plane that exists in src.
Description
XCopyPlane() copies a single plane of a rectangle in the source into the entire depth of a corresponding rectangle in the destination. The plane of the source drawable and the foreground/background pixel values in gc are combined to form a pixmap of the same depth as the destination drawable, and the equivalent of an XCopyArea() is performed, with all the same exposure semantics.
XCopyPlane() uses these graphics context components: function, plane_mask, foreground, background, subwindow_mode, graphics_exposures, clip_x_origin, clip_y_origin, and clip_mask.
The src and dest drawables must have the same root, but need not have the same depth. For more information, see Volume One, Chapter 5, The Graphics Context.
Errors
BadDrawable
BadGC
BadMatchsrc and dest do not have the same root.
BadValueplane does not have exactly one bit set, or bit specified in plane is not a plane in src.
See Also
XClearArea(), XClearWindow(), XCopyArea(), XDraw, XDrawArc(), XDrawArcs(), XDrawFilled(), XDrawLine(), XDrawLines(), XDrawPoint(), XDrawPoints(), XDrawRectangle(), XDrawRectangles(), XDrawSegments(), XFillArc(), XFillArcs(), XFillPolygon(), XFillRectangle(), XFillRectangles().
Copyright O’Reilly & Assoc. —