]> git.saurik.com Git - wxWidgets.git/blob - include/wx/generic/paletteg.h
Fix a couple of warning that crept back into the GTK backend.
[wxWidgets.git] / include / wx / generic / paletteg.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/generic/paletteg.h
3 // Purpose:
4 // Author: Robert Roebling
5 // Created: 01/02/97
6 // RCS-ID: $Id$
7 // Copyright: (c) 1998 Robert Roebling and Julian Smart
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
10
11
12 #ifndef __WX_PALETTEG_H__
13 #define __WX_PALETTEG_H__
14
15 #include "wx/defs.h"
16 #include "wx/object.h"
17 #include "wx/gdiobj.h"
18 #include "wx/gdicmn.h"
19
20 //-----------------------------------------------------------------------------
21 // classes
22 //-----------------------------------------------------------------------------
23
24 class WXDLLIMPEXP_FWD_CORE wxPalette;
25
26 //-----------------------------------------------------------------------------
27 // wxPalette
28 //-----------------------------------------------------------------------------
29
30 class WXDLLIMPEXP_CORE wxPalette: public wxPaletteBase
31 {
32 public:
33 wxPalette();
34 wxPalette( int n, const unsigned char *red, const unsigned char *green, const unsigned char *blue );
35 virtual ~wxPalette();
36
37 bool Create( int n, const unsigned char *red, const unsigned char *green, const unsigned char *blue);
38 int GetPixel( unsigned char red, unsigned char green, unsigned char blue ) const;
39 bool GetRGB( int pixel, unsigned char *red, unsigned char *green, unsigned char *blue ) const;
40
41 virtual int GetColoursCount() const;
42
43 protected:
44 virtual wxGDIRefData *CreateGDIRefData() const;
45 virtual wxGDIRefData *CloneGDIRefData(const wxGDIRefData *data) const;
46
47 private:
48 DECLARE_DYNAMIC_CLASS(wxPalette)
49 };
50
51 #endif // __WX_PALETTEG_H__