8.1 Clearing Areas

Xlib provides functions that you can use to clear an area or the entire window. Because pixmaps do not have defined backgrounds, they cannot be filled by using the functions described in this section. Instead, to accomplish an analogous operation on a pixmap, you should use XFillRectangle(), which sets the pixmap to a known value.

To clear a rectangular area of a given window, use XClearArea().

To clear the entire area in a given window, use XClearWindow().

Next: Copying Areas

Christophe Tronche, ch.tronche@computer.org