Color handling

Last update: 2023-08-31
  • Created for:
  • Developer

The RTF specification permits RGB color values specified with \colortbl. Each component is provided separately with the \red, \green, and \blue commands.

The proprietary RTF extension command \cmykcolortbl allows specifying CMYK colors, with each color component provided with the \cyan, \magenta, \yellow, and \black commands.

Color component values for \colortbl are in the range 0–255. Component values for \cmykcolortbl are in the range 0–100.

The RTF extension command \*\iscolortbl, supported by textPs=, provides a way to specify a color table with standard Image Serving color values, with full RGB, gray, CMYK, and alpha support. It has the following syntax:

{\*\iscolortbl; *colors*;}

colors one or more IS color values, separated with ‘;’

More than one type of color table may be specified in the same text= or textPs= RTF string. Each color table can have a different number of entries. Image Serving attempts to find colors in this order: \iscolortbl before \cmykcolortbl (only if the pixel type of the text layer is CMYK) before \colortbl. For textPs= only, colors are accurately converted between CMYK and RGB, if so required (for example, when RGB colors are specified but CMYK output is required). If no color for a particular index value is found, the default color (black) is used.

Refer to color for a description of the syntax of IS color values.


The modifier text= does not support \*\iscolortbl. The modifier textPs= does not support \cmykcolortbl.

Color selections are ignored when rendering Photofonts.


Allow three text colors to be controlled with variables, while still displaying the color default value when the RTF string is opened in a standard RTF text editor.


On this page