]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/settings.tex
fix ReceiveTimeout() reference
[wxWidgets.git] / docs / latex / wx / settings.tex
CommitLineData
a660d684
KB
1\section{\class{wxSystemSettings}}\label{wxsystemsettings}
2
3wxSystemSettings allows the application to ask for details about
4the system. This can include settings such as standard colours, fonts,
5and 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
a7af285d
VZ
15\wxheading{Library}
16
17\helpref{wxCore}{librarieslist}
18
a660d684
KB
19\wxheading{See also}
20
21\helpref{wxFont}{wxfont}, \helpref{wxColour}{wxcolour}
22
23\latexignore{\rtfignore{\wxheading{Members}}}
24
08f1d438 25\membersection{wxSystemSettings::wxSystemSettings}\label{wxsystemsettingsctor}
a660d684
KB
26
27\func{}{wxSystemSettings}{\void}
28
29Default constructor. You don't need to create an instance of wxSystemSettings
30since all of its functions are static.
31
babeff0d 32\membersection{wxSystemSettings::GetColour}\label{wxsystemsettingsgetcolour}
a660d684 33
babeff0d 34\func{static wxColour}{GetColour}{\param{wxSystemColour}{ index}}
a660d684
KB
35
36Returns a system colour.
37
38{\it index} can be one of:
39
40\twocolwidtha{7cm}
41\begin{twocollist}\itemsep=0pt
42\twocolitem{{\bf wxSYS\_COLOUR\_SCROLLBAR}}{The scrollbar grey area.}
43\twocolitem{{\bf wxSYS\_COLOUR\_BACKGROUND}}{The desktop colour.}
44\twocolitem{{\bf wxSYS\_COLOUR\_ACTIVECAPTION}}{Active window caption.}
45\twocolitem{{\bf wxSYS\_COLOUR\_INACTIVECAPTION}}{Inactive window caption.}
46\twocolitem{{\bf wxSYS\_COLOUR\_MENU}}{Menu background.}
47\twocolitem{{\bf wxSYS\_COLOUR\_WINDOW}}{Window background.}
48\twocolitem{{\bf wxSYS\_COLOUR\_WINDOWFRAME}}{Window frame.}
49\twocolitem{{\bf wxSYS\_COLOUR\_MENUTEXT}}{Menu text.}
50\twocolitem{{\bf wxSYS\_COLOUR\_WINDOWTEXT}}{Text in windows.}
51\twocolitem{{\bf wxSYS\_COLOUR\_CAPTIONTEXT}}{Text in caption, size box and scrollbar arrow box.}
52\twocolitem{{\bf wxSYS\_COLOUR\_ACTIVEBORDER}}{Active window border.}
53\twocolitem{{\bf wxSYS\_COLOUR\_INACTIVEBORDER}}{Inactive window border.}
54\twocolitem{{\bf wxSYS\_COLOUR\_APPWORKSPACE}}{Background colour MDI applications.}
55\twocolitem{{\bf wxSYS\_COLOUR\_HIGHLIGHT}}{Item(s) selected in a control.}
56\twocolitem{{\bf wxSYS\_COLOUR\_HIGHLIGHTTEXT}}{Text of item(s) selected in a control.}
57\twocolitem{{\bf wxSYS\_COLOUR\_BTNFACE}}{Face shading on push buttons.}
58\twocolitem{{\bf wxSYS\_COLOUR\_BTNSHADOW}}{Edge shading on push buttons.}
59\twocolitem{{\bf wxSYS\_COLOUR\_GRAYTEXT}}{Greyed (disabled) text.}
60\twocolitem{{\bf wxSYS\_COLOUR\_BTNTEXT}}{Text on push buttons.}
61\twocolitem{{\bf wxSYS\_COLOUR\_INACTIVECAPTIONTEXT}}{Colour of text in active captions.}
62\twocolitem{{\bf wxSYS\_COLOUR\_BTNHIGHLIGHT}}{Highlight colour for buttons (same as wxSYS\_COLOUR\_3DHILIGHT).}
2edb0bde 63\twocolitem{{\bf wxSYS\_COLOUR\_3DDKSHADOW}}{Dark shadow for three-dimensional display elements.}
a660d684
KB
64\twocolitem{{\bf wxSYS\_COLOUR\_3DLIGHT}}{Light colour for three-dimensional display elements.}
65\twocolitem{{\bf wxSYS\_COLOUR\_INFOTEXT}}{Text colour for tooltip controls.}
66\twocolitem{{\bf wxSYS\_COLOUR\_INFOBK}}{Background colour for tooltip controls.}
67\twocolitem{{\bf wxSYS\_COLOUR\_DESKTOP}}{Same as wxSYS\_COLOUR\_BACKGROUND.}
68\twocolitem{{\bf wxSYS\_COLOUR\_3DFACE}}{Same as wxSYS\_COLOUR\_BTNFACE.}
69\twocolitem{{\bf wxSYS\_COLOUR\_3DSHADOW}}{Same as wxSYS\_COLOUR\_BTNSHADOW.}
70\twocolitem{{\bf wxSYS\_COLOUR\_3DHIGHLIGHT}}{Same as wxSYS\_COLOUR\_BTNHIGHLIGHT.}
71\twocolitem{{\bf wxSYS\_COLOUR\_3DHILIGHT}}{Same as wxSYS\_COLOUR\_BTNHIGHLIGHT.}
72\twocolitem{{\bf wxSYS\_COLOUR\_BTNHILIGHT}}{Same as wxSYS\_COLOUR\_BTNHIGHLIGHT.}
73\end{twocollist}
74
dfa13ec8 75\pythonnote{This static method is implemented in Python as a
babeff0d 76standalone function named {\tt wxSystemSettings\_GetColour}}
dfa13ec8 77
babeff0d 78\membersection{wxSystemSettings::GetFont}\label{wxsystemsettingsgetfont}
a660d684 79
babeff0d 80\func{static wxFont}{GetFont}{\param{wxSystemFont}{ index}}
a660d684
KB
81
82Returns a system font.
83
84{\it index} can be one of:
85
86\twocolwidtha{7cm}
87\begin{twocollist}\itemsep=0pt
88\twocolitem{{\bf wxSYS\_OEM\_FIXED\_FONT}}{Original equipment manufacturer dependent fixed-pitch font.}
89\twocolitem{{\bf wxSYS\_ANSI\_FIXED\_FONT}}{Windows fixed-pitch font.}
90\twocolitem{{\bf wxSYS\_ANSI\_VAR\_FONT}}{Windows variable-pitch (proportional) font.}
91\twocolitem{{\bf wxSYS\_SYSTEM\_FONT}}{System font.}
92\twocolitem{{\bf wxSYS\_DEVICE\_DEFAULT\_FONT}}{Device-dependent font (Windows NT only).}
3cb99894 93\twocolitem{{\bf wxSYS\_DEFAULT\_GUI\_FONT}}{Default font for user interface
d09dd96e
VZ
94objects such as menus and dialog boxes. Note that with modern GUIs nothing
95guarantees that the same font is used for all GUI elements, so some controls
96might use a different font by default.}
a660d684
KB
97\end{twocollist}
98
dfa13ec8 99\pythonnote{This static method is implemented in Python as a
babeff0d 100standalone function named {\tt wxSystemSettings\_GetFont}}
dfa13ec8 101
babeff0d 102\membersection{wxSystemSettings::GetMetric}\label{wxsystemsettingsgetmetric}
a660d684 103
9b0b5ba7 104\func{static int}{GetMetric}{\param{wxSystemMetric}{ index}, \param{wxWindow*}{ win = NULL}}
a660d684 105
9b0b5ba7
RR
106Returns the value of a system metric, or -1 if the metric is not supported on the current system.
107The value of {\it win} determines if the metric returned is a global value or
108a \helpref{wxWindow}{wxwindow} based value, in which case it might determine the widget, the
109display the window is on, or something similar. The window given should be as close to the
40ca9449 110metric as possible (e.g a wxTopLevelWindow in case of the wxSYS\_CAPTION\_Y metric).
a660d684
KB
111
112{\it index} can be one of:
113
114\twocolwidtha{7cm}
115\begin{twocollist}\itemsep=0pt
116\twocolitem{{\bf wxSYS\_MOUSE\_BUTTONS}}{Number of buttons on mouse, or zero if no mouse was installed.}
117\twocolitem{{\bf wxSYS\_BORDER\_X}}{Width of single border.}
118\twocolitem{{\bf wxSYS\_BORDER\_Y}}{Height of single border.}
119\twocolitem{{\bf wxSYS\_CURSOR\_X}}{Width of cursor.}
120\twocolitem{{\bf wxSYS\_CURSOR\_Y}}{Height of cursor.}
121\twocolitem{{\bf wxSYS\_DCLICK\_X}}{Width in pixels of rectangle within which two successive mouse
122clicks must fall to generate a double-click.}
123\twocolitem{{\bf wxSYS\_DCLICK\_Y}}{Height in pixels of rectangle within which two successive mouse
124clicks must fall to generate a double-click.}
5595181f
VZ
125\twocolitem{{\bf wxSYS\_DCLICK\_MSEC}}{Maximal time, in milliseconds, which may
126pass between subsequent clicks for a double click to be generated.}
a660d684
KB
127\twocolitem{{\bf wxSYS\_DRAG\_X}}{Width in pixels of a rectangle centered on a drag point
128to allow for limited movement of the mouse pointer before a drag operation begins.}
129\twocolitem{{\bf wxSYS\_DRAG\_Y}}{Height in pixels of a rectangle centered on a drag point
130to allow for limited movement of the mouse pointer before a drag operation begins.}
131\twocolitem{{\bf wxSYS\_EDGE\_X}}{Width of a 3D border, in pixels. }
132\twocolitem{{\bf wxSYS\_EDGE\_Y}}{Height of a 3D border, in pixels. }
133\twocolitem{{\bf wxSYS\_HSCROLL\_ARROW\_X}}{Width of arrow bitmap on horizontal scrollbar.}
134\twocolitem{{\bf wxSYS\_HSCROLL\_ARROW\_Y}}{Height of arrow bitmap on horizontal scrollbar.}
135\twocolitem{{\bf wxSYS\_HTHUMB\_X}}{Width of horizontal scrollbar thumb.}
136\twocolitem{{\bf wxSYS\_ICON\_X}}{The default width of an icon.}
137\twocolitem{{\bf wxSYS\_ICON\_Y}}{The default height of an icon.}
138\twocolitem{{\bf wxSYS\_ICONSPACING\_X}}{Width of a grid cell for items in large icon view,
139in pixels. Each item fits into a rectangle of this size when arranged.}
140\twocolitem{{\bf wxSYS\_ICONSPACING\_Y}}{Height of a grid cell for items in large icon view,
141in pixels. Each item fits into a rectangle of this size when arranged.}
142\twocolitem{{\bf wxSYS\_WINDOWMIN\_X}}{Minimum width of a window.}
143\twocolitem{{\bf wxSYS\_WINDOWMIN\_Y}}{Minimum height of a window.}
144\twocolitem{{\bf wxSYS\_SCREEN\_X}}{Width of the screen in pixels.}
145\twocolitem{{\bf wxSYS\_SCREEN\_Y}}{Height of the screen in pixels.}
146\twocolitem{{\bf wxSYS\_FRAMESIZE\_X}}{Width of the window frame for a wxTHICK\_FRAME window.}
147\twocolitem{{\bf wxSYS\_FRAMESIZE\_Y}}{Height of the window frame for a wxTHICK\_FRAME window.}
148\twocolitem{{\bf wxSYS\_SMALLICON\_X}}{Recommended width of a small icon (in window captions, and small icon view).}
149\twocolitem{{\bf wxSYS\_SMALLICON\_Y}}{Recommended height of a small icon (in window captions, and small icon view).}
150\twocolitem{{\bf wxSYS\_HSCROLL\_Y}}{Height of horizontal scrollbar in pixels.}
151\twocolitem{{\bf wxSYS\_VSCROLL\_X}}{Width of vertical scrollbar in pixels.}
152\twocolitem{{\bf wxSYS\_VSCROLL\_ARROW\_X}}{Width of arrow bitmap on a vertical scrollbar.}
153\twocolitem{{\bf wxSYS\_VSCROLL\_ARROW\_Y}}{Height of arrow bitmap on a vertical scrollbar.}
154\twocolitem{{\bf wxSYS\_VTHUMB\_Y}}{Height of vertical scrollbar thumb.}
155\twocolitem{{\bf wxSYS\_CAPTION\_Y}}{Height of normal caption area.}
156\twocolitem{{\bf wxSYS\_MENU\_Y}}{Height of single-line menu bar.}
157\twocolitem{{\bf wxSYS\_NETWORK\_PRESENT}}{1 if there is a network present, 0 otherwise.}
158\twocolitem{{\bf wxSYS\_PENWINDOWS\_PRESENT}}{1 if PenWindows is installed, 0 otherwise.}
159\twocolitem{{\bf wxSYS\_SHOW\_SOUNDS}}{Non-zero if the user requires an application to present information visually in situations
160where it would otherwise present the information only in audible form; zero otherwise.}
161\twocolitem{{\bf wxSYS\_SWAP\_BUTTONS}}{Non-zero if the meanings of the left and right mouse buttons are swapped; zero otherwise.}
162\end{twocollist}
163
9b0b5ba7
RR
164{\it win} is a pointer to the window for which the metric is requested.
165Specifying the {\it win} parameter is encouraged, because some metrics on some ports are not supported without one,
166or they might be capable of reporting better values if given one. If a window does not make sense for a metric,
167one should still be given, as for example it might determine which displays cursor width is requested with
40ca9449 168wxSYS\_CURSOR\_X.
9b0b5ba7 169
dfa13ec8 170\pythonnote{This static method is implemented in Python as a
babeff0d 171standalone function named {\tt wxSystemSettings\_GetMetric}}
dfa13ec8 172
dbfb85a7
JS
173\membersection{wxSystemSettings::GetScreenType}\label{wxsystemsettingsgetscreentype}
174
175\func{static wxSystemScreenType}{GetScreenType}{\void}
176
177Returns the screen type. The return value is one of:
178
179\twocolwidtha{7cm}
180\begin{twocollist}\itemsep=0pt
bc8e3ead
RN
181\twocolitem{{\bf wxSYS\_SCREEN\_NONE}}{Undefined screen type}
182\twocolitem{{\bf wxSYS\_SCREEN\_TINY}}{Tiny screen, less than 320x240}
183\twocolitem{{\bf wxSYS\_SCREEN\_PDA}}{PDA screen, 320x240 or more but less than 640x480}
184\twocolitem{{\bf wxSYS\_SCREEN\_SMALL}}{Small screen, 640x480 or more but less than 800x600}
185\twocolitem{{\bf wxSYS\_SCREEN\_DESKTOP}}{Desktop screen, 800x600 or more}
dbfb85a7
JS
186\end{twocollist}
187