XCreatePixmap(3X) — X Version 11
NAME
XCreatePixmap, XFreePixmap − create and destroy pixmaps
SYNTAX
Pixmap XCreatePixmap(display, d, width, height, depth)
Display ∗display;
Drawable d;
unsigned int width, height;
unsigned int depth;
XFreePixmap(display, pixmap)
Display ∗display;
Pixmap pixmap;
ARGUMENTS
dSpecifies which screen the pixmap is created on.
depthSpecifies the depth of the pixmap.
displaySpecifies the connection to the X server.
pixmapSpecifies the pixmap.
width
heightSpecify the width and height.
DESCRIPTION
The XCreatePixmap function creates a pixmap of the width, height, and depth you specified. It also assigns the pixmap ID to it. It is valid to pass a window whose class is InputOnly to the drawable argument. .PN XCreatePixmap can generate BadAlloc, BadDrawable, and BadValue errors.
The XFreePixmap function first deletes the association between the pixmap ID and the pixmap. Then, the X server frees the pixmap storage when no other resources reference it. The pixmap should never be referenced again. .PN XFreePixmap can generate a BadPixmap error.
DIAGNOSTICS
BadAlloc The server failed to allocate the requested resource or server memory.
BadDrawable
A value for a Drawable argument does not name a defined Window or Pixmap.
BadPixmap A value for a Pixmap argument does not name a defined Pixmap.
BadValue Some numeric value falls outside the range of values accepted by the request. Unless a specific range is specified for an argument, the full range defined by the argument’s type is accepted. Any argument defined as a set of alternatives can generate this error.
SEE ALSO
Xlib − C Language X Interface
1 March 1988