]> git.saurik.com Git - wxWidgets.git/blame - interface/wx/colourdata.h
Document that wxStandardPaths::GetUserConfigDir() doesn't use app info.
[wxWidgets.git] / interface / wx / colourdata.h
CommitLineData
4608b3f8
PC
1/////////////////////////////////////////////////////////////////////////////
2// Name: colourdata.h
3// Purpose: interface of wxColourData
4// Author: wxWidgets team
5// RCS-ID: $Id$
6// Licence: wxWindows licence
7/////////////////////////////////////////////////////////////////////////////
8
9/**
10 @class wxColourData
11
12 This class holds a variety of information related to colour dialogs.
13
14 @library{wxcore}
15 @category{cmndlg,data}
16
17 @see wxColour, wxColourDialog, @ref overview_cmndlg_colour
18*/
19class wxColourData : public wxObject
20{
21public:
22 /**
23 Constructor. Initializes the custom colours to @c wxNullColour, the
24 @e data colour setting to black, and the @e choose full setting to
25 @true.
26 */
27 wxColourData();
28
29 /**
30 Destructor.
31 */
32 virtual ~wxColourData();
33
34 /**
35 Under Windows, determines whether the Windows colour dialog will
bd362275
VZ
36 display the full dialog with custom colour selection controls.
37
38 Has no meaning under other platforms.
4608b3f8
PC
39
40 The default value is @true.
41 */
42 bool GetChooseFull() const;
43
44 /**
45 Gets the current colour associated with the colour dialog.
46
47 The default colour is black.
48 */
49 wxColour& GetColour();
50
51 /**
52 Returns custom colours associated with the colour dialog.
53
54 @param i
55 An integer between 0 and 15, being any of the 15 custom colours
56 that the user has saved. The default custom colours are invalid
57 colours.
58 */
59 wxColour GetCustomColour(int i) const;
60
61 /**
62 Under Windows, tells the Windows colour dialog to display the full
63 dialog with custom colour selection controls. Under other platforms,
64 has no effect.
65
66 The default value is @true.
67 */
68 void SetChooseFull(bool flag);
69
70 /**
71 Sets the default colour for the colour dialog.
72
73 The default colour is black.
74 */
75 void SetColour(const wxColour& colour);
76
77 /**
78 Sets custom colours for the colour dialog.
79
80 @param i
81 An integer between 0 and 15 for whatever custom colour you want to
82 set. The default custom colours are invalid colours.
83 @param colour
84 The colour to set
85 */
86 void SetCustomColour(int i, const wxColour& colour);
87
88 /**
d13b34d3 89 Converts the colours saved in this class in a string form, separating
4608b3f8
PC
90 the various colours with a comma.
91 */
92 wxString ToString() const;
93
94 /**
95 Decodes the given string, which should be in the same format returned
96 by ToString(), and sets the internal colours.
97 */
98 bool FromString(const wxString& str);
99
100 /**
101 Assignment operator for the colour data.
102 */
103 wxColourData& operator =(const wxColourData& data);
104};