.\" This is a wxWidgets manpage page generated from the XML docs .TH wxPalette 3wx 2005-02-15 "wxWidgets" "wxWidgets class documentation" .SH NAME wxPalette \- Represents a table of indices into RGB values .SH DESCRIPTION A palette is a table that maps pixel values to RGB colours. It allows the colours of a low-depth bitmap, for example, to be mapped to the available colours in a display. .SH "PARENTS" wxGDIObject wxObject .SH "INCLUDE FILES" wx/palette.h .SH MEMBERS .SS wxPalette () Default constructor. .SS wxPalette (const wxPalette& palette) Copy constructor. This uses reference counting so is a cheap operation. .SS wxPalette (int nconst unsigned char* redconst unsigned char* greenconst unsigned char* blue) Creates a palette from arrays of size n , one for each red, blue or green component. .SS ~wxPalette () Destructor. .SS bool Create (int nconst unsigned char* redconst unsigned char* greenconst unsigned char* blue) Creates a palette from arrays of size n , one for each red, blue or green component. .SS int GetColoursCount () Returns number of entries in palette. .SS int GetPixel (unsigned char redunsigned char greenunsigned char blue) Returns a pixel value (index into the palette) for the given RGB values. .SS bool GetRGB (int pixelconst unsigned char* redconst unsigned char* greenconst unsigned char* blue) Returns RGB values for a given palette index. .SS bool Ok () Returns true if palette data is present. .SS wxPalette& operator = (const wxPalette& palette) Assignment operator, using reference counting. Returns a reference to `this'. .SS bool operator == (const wxPalette& palette) Equality operator. Two palettes are equal if they contain pointers to the same underlying palette data. It does not compare each attribute, so two independently-created palettes using the same parameters will fail the test. .SS bool operator != (const wxPalette& palette) Inequality operator. Two palettes are not equal if they contain pointers to different underlying palette data. It does not compare each attribute. .SH "SEE ALSO" wxGDIObject wxObject wxDC::SetPalette wxBitmap .SH "AUTHORS" Documentation content by Julian Smart, Robert Roebling, Vadim Zeitlin, Robin Dunn, et al Conversion to manpage format by Arnout Engelen (http://bzzt.net), bugreports welcome.