1 /////////////////////////////////////////////////////////////////////////////
4 // Author: Robert Roebling
7 // Copyright: (c) 1998 Robert Roebling, Julian Smart and Markus Holzem
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
12 #ifndef __GTKCOLOURH__
13 #define __GTKCOLOURH__
20 #include "wx/object.h"
21 #include "wx/string.h"
22 #include "wx/gdiobj.h"
23 #include "wx/palette.h"
25 //-----------------------------------------------------------------------------
27 //-----------------------------------------------------------------------------
36 //-----------------------------------------------------------------------------
38 //-----------------------------------------------------------------------------
40 class wxColour
: public wxGDIObject
45 wxColour( char red
, char green
, char blue
);
46 wxColour( const wxString
&colourName
) { InitFromName(colourName
); }
47 wxColour( const char *colourName
) { InitFromName(colourName
); }
48 wxColour( const wxColour
& col
);
49 wxColour( const wxColour
* col
);
51 wxColour
& operator = ( const wxColour
& col
);
52 wxColour
& operator = ( const wxString
& colourName
);
53 bool operator == ( const wxColour
& col
);
54 bool operator != ( const wxColour
& col
);
55 void Set( const unsigned char red
, const unsigned char green
, const unsigned char blue
);
56 unsigned char Red() const;
57 unsigned char Green() const;
58 unsigned char Blue() const;
69 void CalcPixel( GdkColormap
*cmap
);
71 GdkColor
*GetColor() const;
75 void InitFromName(const wxString
& colourName
);
78 DECLARE_DYNAMIC_CLASS(wxColour
)
81 #endif // __GTKCOLOURH__