5.  Colormap Functions  

(color? x)

Returns #t iff x is an object of type color.

(make-color r g b)

Returns an object of type color with the specified RGB components. r, g, and b are reals in the range 0.0 to 1.0.

(color-rgb-values color)

Returns a list of three elements, the RGB components of the given color (see make-color above).

(query-color colormap pixel)

See XQueryColor.

(query-colors colormap pixels)

See XQueryColors. pixels is a vector of pixels. Returns a vector of colors of the same size as pixels.

(lookup-color colormap color-name)

See XLookupColor. color-name is a string or a symbol. Returns a pair of colors.

(alloc-color colormap color)

See XAllocColor. Returns a pixel (or #f in case of an error).

(alloc-named-color colormap color-name)

See AllocNamedColor. color-name is a string or a symbol. Returns a list of three elements: a pixel, and two colors (the closest color and the exact color); or #f in case of an error.

(colormap? x)

Returns #t iff x is an object of type colormap.

(colormap-display colormap)

Returns the display associated with the given colormap.

(free-colormap colormap)

See XFreeColormap.


Markup created by unroff 1.0,    September 24, 1996,    net@informatik.uni-bremen.de