CColorRef Class


The CColorRef class encapsulates an RGB color triplet and provides methods for manipulating the values.

Usage

Construction

Object = CColorRef:new()

Destruction

Object:delete()

Class Properties

These properties hold the data used by each instance of a CColorRef object.

Methods

Construction

new

Creates a new instance of a CColorRef object.

delete

Deletes the instance of the CColorRef object.

Operations

Choose

Opens the Windows ChooseColor tool for changing the color value.

ChoosePal

Opens the Windows ChooseColor tool in "open" mode showing the color palette.

Invert

Inverts the R, G, and B values to form a complementary color.

ToGray

Converts the RGB triplet to a single gray value.

Accessing Properties

Get

Returns the R, G, and B values.

Set

Assigns values to the R, G, and B members.

Related Topics

Script Classes