The pixmaps can be freed immediately if no further explicit references to them are to be made. Subsequent drawing in the source or mask pixmap has an undefined effect on the cursor. The X server might or might not make a copy of the pixmap. XCreatePixmapCursor can generate BadAlloc and BadPixmap errors. To determine useful cursor sizes, use XQueryBestCursor .
Some displays allow larger cursors than other displays.
The XQueryBestCursor function provides a way to find out what size cursors are actually possible on the display. It returns the largest size that can be displayed. Applications should be prepared to use smaller cursors on displays that cannot support large ones. XQueryBestCursor can generate a BadDrawable error. To change the color of a given cursor, use XRecolorCursor .