Contents Up Previous Next

wxColour: wxObject

A colour is an object representing a Red, Green, Blue (RGB) combination of primary colours, and is used to determine drawing colours. See the entry for wxColourDatabase for how a pointer to a predefined, named colour may be returned instead of creating a new colour.

Valid RGB values are in the range 0 to 255.

wxColour::wxColour
wxColour::operator =
wxColour::Blue
wxColour::Get
wxColour::Green
wxColour::Ok
wxColour::Red
wxColour::Set


wxColour::wxColour

void wxColour(char red, char green, char blue)

void wxColour(char * colour_name)

Construct a colour object from the RGB values or using a colour name (uses wxTheColourDatabase).


wxColour::operator =

wxColour& operator =(wxColour& src)

Assignment from source to destination colour.


wxColour::Blue

unsigned char Blue(void)

Returns the blue intensity.


wxColour::Get

void Get(char * red, char * green, char * blue)

Gets the RGB values---pass pointers to three char variables.


wxColour::Green

unsigned char Green(void)

Returns the green intensity.


wxColour::Ok

Bool Ok(void)

Returns TRUE if the colour object is valid.


wxColour::Red

unsigned char Red(void)

Returns the red intensity.


wxColour::Set

void Set(char red, char green, char blue)

Sets the RGB value.