]> git.saurik.com Git - wxWidgets.git/blob - docs/latex/wx/fontdlg.tex
added wxJPEGHandler
[wxWidgets.git] / docs / latex / wx / fontdlg.tex
1 \section{\class{wxFontData}}\label{wxfontdata}
2
3 \overview{wxFontDialog overview}{wxfontdialogoverview}
4
5 This class holds a variety of information related to font dialogs.
6
7 \wxheading{Derived from}
8
9 \helpref{wxObject}{wxobject}
10
11 \wxheading{See also}
12
13 \helpref{Overview}{wxfontdialogoverview}, \helpref{wxFontDialog}{wxfontdialog}
14
15 \latexignore{\rtfignore{\wxheading{Members}}}
16
17 \membersection{wxFontData::wxFontData}
18
19 \func{}{wxFontData}{\void}
20
21 Constructor. Initializes {\it fontColour} to black, {\it showHelp} to black,
22 \rtfsp{\it allowSymbols} to TRUE, {\it enableEffects} to TRUE,
23 \rtfsp{\it minSize} to 0 and {\it maxSize} to 0.
24
25 \membersection{wxFontData::\destruct{wxFontData}}
26
27 \func{}{\destruct{wxFontData}}{\void}
28
29 Destructor.
30
31 \membersection{wxFontData::EnableEffects}
32
33 \func{void}{EnableEffects}{\param{bool}{ enable}}
34
35 Enables or disables `effects' under MS Windows only. This refers to the
36 controls for manipulating colour, strikeout and underline properties.
37
38 The default value is TRUE.
39
40 \membersection{wxFontData::GetAllowSymbols}
41
42 \func{bool}{GetAllowSymbols}{\void}
43
44 Under MS Windows, returns a flag determining whether symbol fonts can be selected. Has no
45 effect on other platforms.
46
47 The default value is TRUE.
48
49 \membersection{wxFontData::GetColour}
50
51 \func{wxColour\&}{GetColour}{\void}
52
53 Gets the colour associated with the font dialog.
54
55 The default value is black.
56
57 \membersection{wxFontData::GetChosenFont}
58
59 \func{wxFont}{GetChosenFont}{\void}
60
61 Gets the font chosen by the user. If the user pressed OK (wxFontDialog::Show returned TRUE), this returns
62 a new font which is now `owned' by the application, and should be deleted
63 if not required. If the user pressed Cancel (wxFontDialog::Show returned FALSE) or
64 the colour dialog has not been invoked yet, this will return NULL.
65
66 \membersection{wxFontData::GetEnableEffects}
67
68 \func{bool}{GetEnableEffects}{\void}
69
70 Determines whether `effects' are enabled under Windows. This refers to the
71 controls for manipulating colour, strikeout and underline properties.
72
73 The default value is TRUE.
74
75 \membersection{wxFontData::GetInitialFont}
76
77 \func{wxFont}{GetInitialFont}{\void}
78
79 Gets the font that will be initially used by the font dialog. This should have
80 previously been set by the application.
81
82 \membersection{wxFontData::GetShowHelp}
83
84 \func{bool}{GetShowHelp}{\void}
85
86 Returns TRUE if the Help button will be shown (Windows only).
87
88 The default value is FALSE.
89
90 \membersection{wxFontData::SetAllowSymbols}
91
92 \func{void}{SetAllowSymbols}{\param{bool}{ allowSymbols}}
93
94 Under MS Windows, determines whether symbol fonts can be selected. Has no
95 effect on other platforms.
96
97 The default value is TRUE.
98
99 \membersection{wxFontData::SetChosenFont}
100
101 \func{void}{SetChosenFont}{\param{const wxFont\& }{font}}
102
103 Sets the font that will be returned to the user (for internal use only).
104
105 \membersection{wxFontData::SetColour}
106
107 \func{void}{SetColour}{\param{const wxColour\&}{ colour}}
108
109 Sets the colour that will be used for the font foreground colour.
110
111 The default colour is black.
112
113 \membersection{wxFontData::SetInitialFont}
114
115 \func{void}{SetInitialFont}{\param{const wxFont\&}{font}}
116
117 Sets the font that will be initially used by the font dialog.
118
119 \membersection{wxFontData::SetRange}
120
121 \func{void}{SetRange}{\param{int}{ min}, \param{int}{ max}}
122
123 Sets the valid range for the font point size (Windows only).
124
125 The default is 0, 0 (unrestricted range).
126
127 \membersection{wxFontData::SetShowHelp}
128
129 \func{void}{SetShowHelp}{\param{bool}{ showHelp}}
130
131 Determines whether the Help button will be displayed in the font dialog (Windows only).
132
133 The default value is FALSE.
134
135 \membersection{wxFontData::operator $=$}
136
137 \func{void}{operator $=$}{\param{const wxFontData\&}{ data}}
138
139 Assingment operator for the font data.
140
141 \section{\class{wxFontDialog}}\label{wxfontdialog}
142
143 This class represents the font chooser dialog.
144
145 \wxheading{Derived from}
146
147 \helpref{wxDialog}{wxdialog}\\
148 \helpref{wxWindow}{wxwindow}\\
149 \helpref{wxEvtHandler}{wxevthandler}\\
150 \helpref{wxObject}{wxobject}
151
152 \wxheading{See also}
153
154 \helpref{Overview}{wxfontdialogoverview}, \helpref{wxFontData}{wxfontdata}
155
156 \latexignore{\rtfignore{\wxheading{Members}}}
157
158 \membersection{wxFontDialog::wxFontDialog}
159
160 \func{}{wxFontDialog}{\param{wxWindow* }{parent}, \param{wxFontData* }{data = NULL}}
161
162 Constructor. Pass a parent window, and optionally a pointer to a block of font
163 data, which will be copied to the font dialog's font data.
164
165 \membersection{wxFontDialog::\destruct{wxFontDialog}}
166
167 \func{}{\destruct{wxFontDialog}}{\void}
168
169 Destructor.
170
171 \membersection{wxFontDialog::GetFontData}
172
173 \func{wxFontData\&}{GetFontData}{\void}
174
175 Returns the \helpref{font data}{wxfontdata} associated with the font dialog.
176
177 \membersection{wxFontDialog::ShowModal}
178
179 \func{int}{ShowModal}{\void}
180
181 Shows the dialog, returning wxID\_OK if the user pressed Ok, and wxID\_CANCEL
182 otherwise.
183
184 If the user cancels the dialog (ShowModal returns wxID\_CANCEL), no font will be
185 created. If the user presses OK (ShowModal returns wxID\_OK), a new wxFont will
186 be created and stored in the font dialog's wxFontData structure.
187