]>
Commit | Line | Data |
---|---|---|
a660d684 KB |
1 | \section{\class{wxSystemSettings}}\label{wxsystemsettings} |
2 | ||
3 | wxSystemSettings allows the application to ask for details about | |
4 | the system. This can include settings such as standard colours, fonts, | |
5 | and user interface element sizes. | |
6 | ||
7 | \wxheading{Derived from} | |
8 | ||
9 | \helpref{wxObject}{wxobject} | |
10 | ||
954b8ae6 JS |
11 | \wxheading{Include files} |
12 | ||
13 | <wx/settings.h> | |
14 | ||
a660d684 KB |
15 | \wxheading{See also} |
16 | ||
17 | \helpref{wxFont}{wxfont}, \helpref{wxColour}{wxcolour} | |
18 | ||
19 | \latexignore{\rtfignore{\wxheading{Members}}} | |
20 | ||
21 | \membersection{wxSystemSettings::wxSystemSettings} | |
22 | ||
23 | \func{}{wxSystemSettings}{\void} | |
24 | ||
25 | Default constructor. You don't need to create an instance of wxSystemSettings | |
26 | since all of its functions are static. | |
27 | ||
babeff0d | 28 | \membersection{wxSystemSettings::GetColour}\label{wxsystemsettingsgetcolour} |
a660d684 | 29 | |
babeff0d | 30 | \func{static wxColour}{GetColour}{\param{wxSystemColour}{ index}} |
a660d684 KB |
31 | |
32 | Returns a system colour. | |
33 | ||
34 | {\it index} can be one of: | |
35 | ||
36 | \twocolwidtha{7cm} | |
37 | \begin{twocollist}\itemsep=0pt | |
38 | \twocolitem{{\bf wxSYS\_COLOUR\_SCROLLBAR}}{The scrollbar grey area.} | |
39 | \twocolitem{{\bf wxSYS\_COLOUR\_BACKGROUND}}{The desktop colour.} | |
40 | \twocolitem{{\bf wxSYS\_COLOUR\_ACTIVECAPTION}}{Active window caption.} | |
41 | \twocolitem{{\bf wxSYS\_COLOUR\_INACTIVECAPTION}}{Inactive window caption.} | |
42 | \twocolitem{{\bf wxSYS\_COLOUR\_MENU}}{Menu background.} | |
43 | \twocolitem{{\bf wxSYS\_COLOUR\_WINDOW}}{Window background.} | |
44 | \twocolitem{{\bf wxSYS\_COLOUR\_WINDOWFRAME}}{Window frame.} | |
45 | \twocolitem{{\bf wxSYS\_COLOUR\_MENUTEXT}}{Menu text.} | |
46 | \twocolitem{{\bf wxSYS\_COLOUR\_WINDOWTEXT}}{Text in windows.} | |
47 | \twocolitem{{\bf wxSYS\_COLOUR\_CAPTIONTEXT}}{Text in caption, size box and scrollbar arrow box.} | |
48 | \twocolitem{{\bf wxSYS\_COLOUR\_ACTIVEBORDER}}{Active window border.} | |
49 | \twocolitem{{\bf wxSYS\_COLOUR\_INACTIVEBORDER}}{Inactive window border.} | |
50 | \twocolitem{{\bf wxSYS\_COLOUR\_APPWORKSPACE}}{Background colour MDI applications.} | |
51 | \twocolitem{{\bf wxSYS\_COLOUR\_HIGHLIGHT}}{Item(s) selected in a control.} | |
52 | \twocolitem{{\bf wxSYS\_COLOUR\_HIGHLIGHTTEXT}}{Text of item(s) selected in a control.} | |
53 | \twocolitem{{\bf wxSYS\_COLOUR\_BTNFACE}}{Face shading on push buttons.} | |
54 | \twocolitem{{\bf wxSYS\_COLOUR\_BTNSHADOW}}{Edge shading on push buttons.} | |
55 | \twocolitem{{\bf wxSYS\_COLOUR\_GRAYTEXT}}{Greyed (disabled) text.} | |
56 | \twocolitem{{\bf wxSYS\_COLOUR\_BTNTEXT}}{Text on push buttons.} | |
57 | \twocolitem{{\bf wxSYS\_COLOUR\_INACTIVECAPTIONTEXT}}{Colour of text in active captions.} | |
58 | \twocolitem{{\bf wxSYS\_COLOUR\_BTNHIGHLIGHT}}{Highlight colour for buttons (same as wxSYS\_COLOUR\_3DHILIGHT).} | |
2edb0bde | 59 | \twocolitem{{\bf wxSYS\_COLOUR\_3DDKSHADOW}}{Dark shadow for three-dimensional display elements.} |
a660d684 KB |
60 | \twocolitem{{\bf wxSYS\_COLOUR\_3DLIGHT}}{Light colour for three-dimensional display elements.} |
61 | \twocolitem{{\bf wxSYS\_COLOUR\_INFOTEXT}}{Text colour for tooltip controls.} | |
62 | \twocolitem{{\bf wxSYS\_COLOUR\_INFOBK}}{Background colour for tooltip controls.} | |
63 | \twocolitem{{\bf wxSYS\_COLOUR\_DESKTOP}}{Same as wxSYS\_COLOUR\_BACKGROUND.} | |
64 | \twocolitem{{\bf wxSYS\_COLOUR\_3DFACE}}{Same as wxSYS\_COLOUR\_BTNFACE.} | |
65 | \twocolitem{{\bf wxSYS\_COLOUR\_3DSHADOW}}{Same as wxSYS\_COLOUR\_BTNSHADOW.} | |
66 | \twocolitem{{\bf wxSYS\_COLOUR\_3DHIGHLIGHT}}{Same as wxSYS\_COLOUR\_BTNHIGHLIGHT.} | |
67 | \twocolitem{{\bf wxSYS\_COLOUR\_3DHILIGHT}}{Same as wxSYS\_COLOUR\_BTNHIGHLIGHT.} | |
68 | \twocolitem{{\bf wxSYS\_COLOUR\_BTNHILIGHT}}{Same as wxSYS\_COLOUR\_BTNHIGHLIGHT.} | |
69 | \end{twocollist} | |
70 | ||
dfa13ec8 | 71 | \pythonnote{This static method is implemented in Python as a |
babeff0d | 72 | standalone function named {\tt wxSystemSettings\_GetColour}} |
dfa13ec8 | 73 | |
babeff0d | 74 | \membersection{wxSystemSettings::GetFont}\label{wxsystemsettingsgetfont} |
a660d684 | 75 | |
babeff0d | 76 | \func{static wxFont}{GetFont}{\param{wxSystemFont}{ index}} |
a660d684 KB |
77 | |
78 | Returns a system font. | |
79 | ||
80 | {\it index} can be one of: | |
81 | ||
82 | \twocolwidtha{7cm} | |
83 | \begin{twocollist}\itemsep=0pt | |
84 | \twocolitem{{\bf wxSYS\_OEM\_FIXED\_FONT}}{Original equipment manufacturer dependent fixed-pitch font.} | |
85 | \twocolitem{{\bf wxSYS\_ANSI\_FIXED\_FONT}}{Windows fixed-pitch font.} | |
86 | \twocolitem{{\bf wxSYS\_ANSI\_VAR\_FONT}}{Windows variable-pitch (proportional) font.} | |
87 | \twocolitem{{\bf wxSYS\_SYSTEM\_FONT}}{System font.} | |
88 | \twocolitem{{\bf wxSYS\_DEVICE\_DEFAULT\_FONT}}{Device-dependent font (Windows NT only).} | |
3cb99894 VZ |
89 | \twocolitem{{\bf wxSYS\_DEFAULT\_GUI\_FONT}}{Default font for user interface |
90 | objects such as menus and dialog boxes.} | |
91 | \twocolitem{{\bf wxSYS\_ICONTITLE\_FONT}}{Font for the icon titles (Windows | |
92 | only, same as default GUI font on other platforms} | |
a660d684 KB |
93 | \end{twocollist} |
94 | ||
dfa13ec8 | 95 | \pythonnote{This static method is implemented in Python as a |
babeff0d | 96 | standalone function named {\tt wxSystemSettings\_GetFont}} |
dfa13ec8 | 97 | |
babeff0d | 98 | \membersection{wxSystemSettings::GetMetric}\label{wxsystemsettingsgetmetric} |
a660d684 | 99 | |
babeff0d | 100 | \func{static int}{GetMetric}{\param{wxSystemMetric}{ index}} |
a660d684 KB |
101 | |
102 | Returns a system metric. | |
103 | ||
104 | {\it index} can be one of: | |
105 | ||
106 | \twocolwidtha{7cm} | |
107 | \begin{twocollist}\itemsep=0pt | |
108 | \twocolitem{{\bf wxSYS\_MOUSE\_BUTTONS}}{Number of buttons on mouse, or zero if no mouse was installed.} | |
109 | \twocolitem{{\bf wxSYS\_BORDER\_X}}{Width of single border.} | |
110 | \twocolitem{{\bf wxSYS\_BORDER\_Y}}{Height of single border.} | |
111 | \twocolitem{{\bf wxSYS\_CURSOR\_X}}{Width of cursor.} | |
112 | \twocolitem{{\bf wxSYS\_CURSOR\_Y}}{Height of cursor.} | |
113 | \twocolitem{{\bf wxSYS\_DCLICK\_X}}{Width in pixels of rectangle within which two successive mouse | |
114 | clicks must fall to generate a double-click.} | |
115 | \twocolitem{{\bf wxSYS\_DCLICK\_Y}}{Height in pixels of rectangle within which two successive mouse | |
116 | clicks must fall to generate a double-click.} | |
117 | \twocolitem{{\bf wxSYS\_DRAG\_X}}{Width in pixels of a rectangle centered on a drag point | |
118 | to allow for limited movement of the mouse pointer before a drag operation begins.} | |
119 | \twocolitem{{\bf wxSYS\_DRAG\_Y}}{Height in pixels of a rectangle centered on a drag point | |
120 | to allow for limited movement of the mouse pointer before a drag operation begins.} | |
121 | \twocolitem{{\bf wxSYS\_EDGE\_X}}{Width of a 3D border, in pixels. } | |
122 | \twocolitem{{\bf wxSYS\_EDGE\_Y}}{Height of a 3D border, in pixels. } | |
123 | \twocolitem{{\bf wxSYS\_HSCROLL\_ARROW\_X}}{Width of arrow bitmap on horizontal scrollbar.} | |
124 | \twocolitem{{\bf wxSYS\_HSCROLL\_ARROW\_Y}}{Height of arrow bitmap on horizontal scrollbar.} | |
125 | \twocolitem{{\bf wxSYS\_HTHUMB\_X}}{Width of horizontal scrollbar thumb.} | |
126 | \twocolitem{{\bf wxSYS\_ICON\_X}}{The default width of an icon.} | |
127 | \twocolitem{{\bf wxSYS\_ICON\_Y}}{The default height of an icon.} | |
128 | \twocolitem{{\bf wxSYS\_ICONSPACING\_X}}{Width of a grid cell for items in large icon view, | |
129 | in pixels. Each item fits into a rectangle of this size when arranged.} | |
130 | \twocolitem{{\bf wxSYS\_ICONSPACING\_Y}}{Height of a grid cell for items in large icon view, | |
131 | in pixels. Each item fits into a rectangle of this size when arranged.} | |
132 | \twocolitem{{\bf wxSYS\_WINDOWMIN\_X}}{Minimum width of a window.} | |
133 | \twocolitem{{\bf wxSYS\_WINDOWMIN\_Y}}{Minimum height of a window.} | |
134 | \twocolitem{{\bf wxSYS\_SCREEN\_X}}{Width of the screen in pixels.} | |
135 | \twocolitem{{\bf wxSYS\_SCREEN\_Y}}{Height of the screen in pixels.} | |
136 | \twocolitem{{\bf wxSYS\_FRAMESIZE\_X}}{Width of the window frame for a wxTHICK\_FRAME window.} | |
137 | \twocolitem{{\bf wxSYS\_FRAMESIZE\_Y}}{Height of the window frame for a wxTHICK\_FRAME window.} | |
138 | \twocolitem{{\bf wxSYS\_SMALLICON\_X}}{Recommended width of a small icon (in window captions, and small icon view).} | |
139 | \twocolitem{{\bf wxSYS\_SMALLICON\_Y}}{Recommended height of a small icon (in window captions, and small icon view).} | |
140 | \twocolitem{{\bf wxSYS\_HSCROLL\_Y}}{Height of horizontal scrollbar in pixels.} | |
141 | \twocolitem{{\bf wxSYS\_VSCROLL\_X}}{Width of vertical scrollbar in pixels.} | |
142 | \twocolitem{{\bf wxSYS\_VSCROLL\_ARROW\_X}}{Width of arrow bitmap on a vertical scrollbar.} | |
143 | \twocolitem{{\bf wxSYS\_VSCROLL\_ARROW\_Y}}{Height of arrow bitmap on a vertical scrollbar.} | |
144 | \twocolitem{{\bf wxSYS\_VTHUMB\_Y}}{Height of vertical scrollbar thumb.} | |
145 | \twocolitem{{\bf wxSYS\_CAPTION\_Y}}{Height of normal caption area.} | |
146 | \twocolitem{{\bf wxSYS\_MENU\_Y}}{Height of single-line menu bar.} | |
147 | \twocolitem{{\bf wxSYS\_NETWORK\_PRESENT}}{1 if there is a network present, 0 otherwise.} | |
148 | \twocolitem{{\bf wxSYS\_PENWINDOWS\_PRESENT}}{1 if PenWindows is installed, 0 otherwise.} | |
149 | \twocolitem{{\bf wxSYS\_SHOW\_SOUNDS}}{Non-zero if the user requires an application to present information visually in situations | |
150 | where it would otherwise present the information only in audible form; zero otherwise.} | |
151 | \twocolitem{{\bf wxSYS\_SWAP\_BUTTONS}}{Non-zero if the meanings of the left and right mouse buttons are swapped; zero otherwise.} | |
152 | \end{twocollist} | |
153 | ||
dfa13ec8 | 154 | \pythonnote{This static method is implemented in Python as a |
babeff0d | 155 | standalone function named {\tt wxSystemSettings\_GetMetric}} |
dfa13ec8 | 156 |