A color model is a way of representing colors. LaTeX’s capabilities depend on the printer driver. However, the pdftex, xetex, and luatex printer drivers are today by far the most commonly used. The models below work for those drivers. All but one of these is also supported by essentially all other printer drivers used today.
Note that color combination can be additive or subtractive. Additive mixes colors of light, so that for instance combining full intensities of red, green, and blue produces white. Subtractive mixes pigments, such as with inks, so that combining full intensity of cyan, magenta, and yellow makes black.
A comma-separated list with four real numbers between 0 and 1, inclusive. The first number is the intensity of cyan, the second is magenta, and the others are yellow and black. A number value of 0 means minimal intensity, while a 1 is for full intensity. This model is often used in color printing. It is a subtractive model.
A single real number between 0 and 1, inclusive. The colors are shades of grey. The number 0 produces black while 1 gives white.
A comma-separated list with three real numbers between 0 and 1, inclusive. The first number is the intensity of the red component, the second is green, and the third the blue. A number value of 0 means that none of that component is added in, while a 1 means full intensity. This is an additive model.
(pdftex, xetex, luatex drivers) A comma-separated list with three integers between 0 and 255, inclusive. This model is a convenience for using
rgb since outside of LaTeX colors are often described in a red-green-blue model using numbers in this range. The values entered here are converted to the
rgb model by dividing by 255.
Colors are accessed by name, such as ‘PrussianBlue’. The list of names depends on the driver, but all support the names ‘black’, ‘blue’, ‘cyan’, ‘green’, ‘magenta’, ‘red’, ‘white’, and ‘yellow’ (See the
dvipsnames option in Color package options).
© 2007–2018 Karl Berry
Public Domain Software