NAME
XmuLookupStandardColormap — create a standard colormap if not already created.
SYNOPSIS
#include <X11/Xmu/StdCmap.h>
XmuLookupStandardColormap(display, screen, visualid, depth, property,
replace, retain)
Display ∗display;
int screen;
VisualID visualid;
unsigned int depth;
Atom property;
Bool replace;
Bool retain;
ARGUMENTS
displaySpecifies a connection to an X server; returned from XOpenDisplay().
screenSpecifies the screen of the display.
visualidSpecifies the visual type.
depthSpecifies the visual depth.
propertySpecifies the standard colormap property.
replaceSpecifies whether or not to replace.
retainSpecifies whether or not to retain.
DESCRIPTION
XmuLookupStandardColormap creates a standard colormap if one does not currently exist, or replaces the currently existing standard colormap.
Given a screen, a visual, and a property, this function will determine the best allocation for the property under the specified visual, and determine whether to create a new colormap or to use the default colormap of the screen.
If replace is True, any previous definition of the property will be replaced. If retain is True, the property and the colormap will be made permanent for the duration of the server session. However, pre-existing property definitions which are not replaced cannot be made permanent by a call to this function; a request to retain resources pertains to newly created resources.
XmuLookupStandardColormap returns zero on failure, non-zero on success. A request to create a standard colormap upon a visual which cannot support such a map is considered a failure. An example of this would be requesting any standard colormap property on a monochrome visual, or, requesting an RGB_BEST_MAP on a display whose colormap size is 16.
SEE ALSO
XmuAllStandardColormaps, XmuCreateColormap, XmuDeleteStandardColormap, XmuGetColormapAllocation, XmuStandardColormap, XmuVisualStandardColormaps.
Xlib Reference Manual