DekGenius.com
Team LiB   Previous Section   Next Section
RGB color

Allowed coercion

list

Syntax

set myRGB to {0,0,0} as RGB color (* returns the color black as an RGB Color 
value *)

Description

RGB color values are lists of three integers (between and 65535) that represent the red, green, and blue components of a color. The script commands for a graphics application may take or return RGB color values, for example. The class of an RGB color is actually a list value:

set myRGB to {0,0,0} as RGB color

get class of myRGB -- returns list

You can change the values in an RGB color object by referring to its item property:

set item 3 of myRGB to 10000.
    Team LiB   Previous Section   Next Section