A device-independent color management system, Xcms, was contributed to the X Window System distribution with X11 Release 5 in 1991. Xcms was based on the TekColor color management system by Tektronix, Inc. However, the book version of the documentation, (A Technical Introduction to) The X Color Management System by Al Tabayoyon, Joann Taylor and Chuck Adams of Tektronix, Inc. was never published by O'Reilly and Associates, Inc. This page collects information for those who wish to hack Xcms but are having trouble finding documentation.
Xcms comes from an era (1991) when 8 bit color displays were the norm on UNIX workstations. Therefore it is primarily concerned with converting device-independent colors to the RGB values used in video framebuffer lookup tables driving CRT monitors. There are extensions for installing new colorspaces, such as sRGB, but as Xcms also predates the ICC, there are no tools for reading and writing ICC profiles.
Xcms consists of two main parts, the X Device Color Characterization Convention (XDCCC) and the Xlib API.
The XDCCC describes the mathematical formulas used to convert from device-independent CIEXYZ colorspace to the device-dependent, non-linearly quantized RGB colorspace used in the X protocol. It also describes the form in which this DDC information is stored in the root window of an X server display screen. This allows any client to query a screen for the information, and implement a conversion from CIEXYZ to X protocol RGB so that a device-independent color appears properly on the screen.
The Xcms API in Xlib provides an interface to the standard X colormap functions, but allows color table reads/writes in device-independent colors as well as non-linear RGB. The Xcms API uses the DCC data loaded into the root window properties by xcmsdb.
Information from several places within the X11R4 and X11R6.6 source distribution follows.
The X11R6.6 release notes (ASCII, 16k) contain this information.
The primary reference for the XDCCC is Section 7 (PDF, 29k) of the Inter-Client Communication Conventions Manual (ICCCM). The original draft (PDF, 12k) of the XDCCC was distributed with X11R4. The xcmsdb man page (PDF, 7k) describes how to load XDCCC properties into the root window using a Device Color Characterization (DCC) file. Two samples of DCC files, sample1.dcc (ASCII, 27k) and sample2.dcc (ASCII, 26k) are provided.
The primary reference for the Xcms API is Chapter 6 (PDF, 292k) of Xlib - C Language X Interface programmer's guide. The original draft (PDF, 83k) and index (PDF, 4.5k) of the API were distributed with X11R4.