Development Topics > GDI Printing > GDI Printing Directives

SETTEXTCOLOR

//SETTEXTCOLOR, r, g, b

SETTEXTCOLOR sets the color to be used for subsequent text output.

The r (red), g (green), b (blue) values may each range from 0-255. You can use these to specify virtually any color (whether or not your printer actually supports it.) To figure out the values for special colors, you can use the Settings | Colors dialog in A-Shell. Click on a color, then select the Define Custom Color button and you will see a dialog which allows you to select any color from a three-dimensional grid. (The third dimension is a slide bar on the right side that controls lightness and darkness.) As you move the color cursor around, you will see the color values changing. (Don't confuse them with the Hue, Saturation, and Luminescence values, which are part of an alternative system of defining colors.) Some common color values are shown below.

R,G,B

Color

 

R,G,B

Color

0,0,0

Black

 

192,192,192

Gray

255,255,255

White

 

255,0,255

Magenta (intense)

255,0,0

Red (intense)

 

183,231,58

Lime green