tbx  0.7.5
Public Types | Public Member Functions | List of all members
tbx::WimpColour Class Reference

Class to represent a standard desktop WIMP colour. More...

#include <colour.h>

Public Types

enum  {
  white = 0, grey0 = 0, grey1 = 1, grey2 = 2,
  grey3 = 3, grey4 = 4, grey5 = 5, grey6 = 6,
  grey7 = 7, black = 7, dark_blue = 8, yellow = 9,
  light_green = 10, red = 11, cream = 12, dark_green = 13,
  orange = 14, light_blue = 15, no_colour = -1, minimum = 0,
  maximum = 15
}
 Enumeration specifying all the possible WIMP colours.
 

Public Member Functions

 WimpColour ()
 Constructor creates black WIMP colour.
 
 WimpColour (int c)
 Construct from an integer colour number. More...
 
 operator int () const
 Return colour number. More...
 
WimpColouroperator= (int c)
 Set colour number. More...
 

Detailed Description

Class to represent a standard desktop WIMP colour.

This is an integer from 0 to 15 or -1 for no colour.

Constructor & Destructor Documentation

◆ WimpColour()

tbx::WimpColour::WimpColour ( int  c)
inline

Construct from an integer colour number.

Parameters
ccolour number -1 to 15.

Member Function Documentation

◆ operator int()

tbx::WimpColour::operator int ( ) const
inline

Return colour number.

Returns
colour number from -1 to 15

◆ operator=()

WimpColour& tbx::WimpColour::operator= ( int  c)
inline

Set colour number.

Parameters
ccolour number from -1 to 15
Returns
reference to this object

The documentation for this class was generated from the following file: