]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/htwinprs.tex
RemoveAt() added to array classes
[wxWidgets.git] / docs / latex / wx / htwinprs.tex
CommitLineData
704a4b75
VS
1%
2% automatically generated by HelpGen from
3% htmlwinparser.tex at 14/Mar/99 20:13:37
4%
5
704a4b75
VS
6\section{\class{wxHtmlWinParser}}\label{wxhtmlwinparser}
7
704a4b75
VS
8This class is derived from \helpref{wxHtmlParser}{wxhtmlparser} and
9its mail goal is to parse HTML input so that it can be displayed in
10\helpref{wxHtmlWindow}{wxhtmlwindow}. It uses special
11\helpref{wxHtmlWinTagHandler}{wxhtmlwintaghandler}.
12
13\wxheading{Notes}
14
15\begin{enumerate}
16\item Product of parsing is wxHtmlCell (resp. wxHtmlContainer) object.
17\item This parser produces temporary data! You should call
18\helpref{delete GetTempData()}{wxhtmlparsergettempdata}!
19\end{enumerate}
20
704a4b75
VS
21\wxheading{Derived from}
22
23\helpref{wxHtmlParser}{wxhtmlparser}
24
25\wxheading{See Also}
26
27\helpref{Handlers overview}{handlers}
28
29\latexignore{\rtfignore{\wxheading{Members}}}
30
31\membersection{wxHtmlWinParser::wxHtmlWinParser}\label{wxhtmlwinparserwxhtmlwinparser}
32
33\func{}{wxHtmlWinParser}{\void}
34
35\func{}{wxHtmlWinParser}{\param{wxWindow }{*wnd}}
36
37Constructor. Don't use the default one, use constructor with
38{\it wnd} paremeter ({\it wnd} is pointer to associated \helpref{wxHtmlWindow}{wxhtmlwindow})
39
559fe022 40\membersection{wxHtmlWinParser::AddModule}\label{wxhtmlwinparseraddmodule}
704a4b75 41
559fe022 42\func{static void}{AddModule}{\param{wxHtmlTagsModule }{*module}}
704a4b75 43
559fe022 44Adds \helpref{module}{handlers} to the list of wxHtmlWinParser tag handler.
704a4b75 45
559fe022 46\membersection{wxHtmlWinParser::CloseContainer}\label{wxhtmlwinparserclosecontainer}
704a4b75 47
559fe022 48\func{wxHtmlContainerCell*}{CloseContainer}{\void}
704a4b75 49
559fe022
VS
50Closes the container, sets actual container to the parent one
51and returns pointer to it (see \helpref{Overview}{cells}).
704a4b75 52
559fe022 53\membersection{wxHtmlWinParser::CreateCurrentFont}\label{wxhtmlwinparsercreatecurrentfont}
704a4b75 54
559fe022 55\func{virtual wxFont*}{CreateCurrentFont}{\void}
704a4b75 56
559fe022
VS
57Creates font based on current setting (see
58\helpref{SetFontSize}{wxhtmlwinparsersetfontsize},
59\helpref{SetFontBold}{wxhtmlwinparsersetfontbold},
60\helpref{SetFontItalic}{wxhtmlwinparsersetfontitalic},
61\helpref{SetFontFixed}{wxhtmlwinparsersetfontfixed},
62\helpref{SetFontUnderlined}{wxhtmlwinparsersetfontunderlined})
63and returns pointer to it.
64(If the font was already created only a pointer is returned.)
704a4b75 65
559fe022
VS
66Fonts created during parsing are temporary data and are not freed on DoneParser.
67You must call \helpref{delete myparser->GetTempData();}{wxhtmlparsergettempdata}
68to free the memory!
704a4b75 69
559fe022 70\membersection{wxHtmlWinParser::GetActualColor}\label{wxhtmlwinparsergetactualcolor}
704a4b75 71
559fe022 72\constfunc{const wxColour\&}{GetActualColor}{\void}
704a4b75 73
559fe022 74Returns actual text color.
704a4b75 75
559fe022 76\membersection{wxHtmlWinParser::GetAlign}\label{wxhtmlwinparsergetalign}
704a4b75 77
559fe022 78\constfunc{int}{GetAlign}{\void}
704a4b75 79
559fe022 80Returns default horizontal alignment.
704a4b75 81
559fe022 82\membersection{wxHtmlWinParser::GetCharHeight}\label{wxhtmlwinparsergetcharheight}
704a4b75 83
559fe022 84\constfunc{int}{GetCharHeight}{\void}
704a4b75 85
559fe022 86Returns (average) char height in standard font. It's used as DC-independent metrics.
704a4b75 87
448af9a4
JS
88{\bf Note:} This function doesn't return {\it actual} height. If you want to
89know the height of the current font, call {\tt GetDC -> GetCharHeight()}.
704a4b75 90
559fe022 91\membersection{wxHtmlWinParser::GetCharWidth}\label{wxhtmlwinparsergetcharwidth}
704a4b75 92
559fe022 93\constfunc{int}{GetCharWidth}{\void}
704a4b75 94
559fe022 95Returns average char width in standard font. It's used as DC-independent metrics.
704a4b75 96
448af9a4
JS
97{\bf Note:} This function doesn't return {\it actual} width. If you want to
98know the height of the current font, call {\tt GetDC -> GetCharWidth()}
704a4b75 99
704a4b75
VS
100\membersection{wxHtmlWinParser::GetContainer}\label{wxhtmlwinparsergetcontainer}
101
102\constfunc{wxHtmlContainerCell*}{GetContainer}{\void}
103
104Returns pointer to the currectly opened container (see \helpref{Overview}{cells}).
105Common use:
106
107\begin{verbatim}
108m_WParser -> GetContainer() -> InsertCell(new ...);
109\end{verbatim}
110
559fe022 111\membersection{wxHtmlWinParser::GetDC}\label{wxhtmlwinparsergetdc}
704a4b75 112
559fe022 113\func{wxDC*}{GetDC}{\void}
704a4b75 114
559fe022 115Returns pointer to the DC used during parsing.
704a4b75
VS
116
117\membersection{wxHtmlWinParser::GetFontBold}\label{wxhtmlwinparsergetfontbold}
118
119\constfunc{int}{GetFontBold}{\void}
120
121Returns TRUE if actual font is bold, FALSE otherwise.
122
559fe022 123\membersection{wxHtmlWinParser::GetFontFixed}\label{wxhtmlwinparsergetfontfixed}
704a4b75 124
559fe022 125\constfunc{int}{GetFontFixed}{\void}
704a4b75 126
559fe022 127Returns TRUE if actual font is fixed face, FALSE otherwise.
704a4b75
VS
128
129\membersection{wxHtmlWinParser::GetFontItalic}\label{wxhtmlwinparsergetfontitalic}
130
131\constfunc{int}{GetFontItalic}{\void}
132
133Returns TRUE if actual font is italic, FALSE otherwise.
134
135
559fe022 136\membersection{wxHtmlWinParser::GetFontSize}\label{wxhtmlwinparsergetfontsize}
704a4b75 137
559fe022 138\constfunc{int}{GetFontSize}{\void}
704a4b75 139
559fe022 140Returns actual font size (HTML size varies from -2 to +4)
704a4b75
VS
141
142\membersection{wxHtmlWinParser::GetFontUnderlined}\label{wxhtmlwinparsergetfontunderlined}
143
144\constfunc{int}{GetFontUnderlined}{\void}
145
146Returns TRUE if actual font is underlined, FALSE otherwise.
147
559fe022 148\membersection{wxHtmlWinParser::GetLink}\label{wxhtmlwinparsergetlink}
704a4b75 149
559fe022 150\constfunc{const wxString\&}{GetLink}{\void}
704a4b75 151
559fe022
VS
152Returns actual hypertext link. (This value is non-empty string
153if the parser is between {\tt <A>} and {\tt </A>} tags,
154wxEmptyString otherwise.
704a4b75 155
704a4b75 156
559fe022 157\membersection{wxHtmlWinParser::GetLinkColor}\label{wxhtmlwinparsergetlinkcolor}
704a4b75 158
559fe022 159\constfunc{const wxColour\&}{GetLinkColor}{\void}
704a4b75 160
559fe022 161Returns color of hypertext link text.
704a4b75 162
559fe022 163\membersection{wxHtmlWinParser::GetWindow}\label{wxhtmlwinparsergetwindow}
704a4b75 164
559fe022 165\func{wxWindow*}{GetWindow}{\void}
704a4b75 166
559fe022
VS
167Returns associated window (wxHtmlWindow). This may be NULL! (You should always
168test if it is non-NULL. For example {\tt TITLE} handler sets window
169title only if some window is associated, otherwise it does nothing)
704a4b75 170
704a4b75 171
559fe022
VS
172\membersection{wxHtmlWinParser::OpenContainer}\label{wxhtmlwinparseropencontainer}
173
174\func{wxHtmlContainerCell*}{OpenContainer}{\void}
175
176Opens new container and returns pointer to it (see \helpref{Overview}{cells}).
177
178%
179\membersection{wxHtmlWinParser::SetActualColor}\label{wxhtmlwinparsersetactualcolor}
180
181\func{void}{SetActualColor}{\param{const wxColour\& }{clr}}
182
183Sets actual text color. Note: this DOESN'T change the color!
184You must create \helpref{wxHtmlColourCell}{wxhtmlcolourcell} yourself.
704a4b75
VS
185
186\membersection{wxHtmlWinParser::SetAlign}\label{wxhtmlwinparsersetalign}
187
188\func{void}{SetAlign}{\param{int }{a}}
189
190Sets default horizontal alignment (see \helpref{wxHtmlContainerCell::SetAlignHor}{wxhtmlcontainercellsetalignhor}.
191Alignment of newly opened container is set to this value.
192
559fe022
VS
193%\membersection{wxHtmlWinParser::SetContainer}\label{wxhtmlwinparsersetcontainer}
194%
195%\func{wxHtmlContainerCell*}{SetContainer}{\param{wxHtmlContainerCell *}{c}}
196%
197%Allows you to directly set opened container. This is not recommended - you should use OpenContainer
198%whereever possible.
199%
704a4b75 200
559fe022 201\membersection{wxHtmlWinParser::SetDC}\label{wxhtmlwinparsersetdc}
704a4b75 202
559fe022 203\func{virtual void}{SetDC}{\param{wxDC }{*dc}}
704a4b75 204
559fe022 205Sets the DC. This must be called before \helpref{Parse}{wxhtmlparserparse}!
704a4b75 206
559fe022 207\membersection{wxHtmlWinParser::SetFontBold}\label{wxhtmlwinparsersetfontbold}
704a4b75 208
559fe022 209\func{void}{SetFontBold}{\param{int }{x}}
704a4b75 210
559fe022 211Sets bold flag of actualfont. {\it x} is either TRUE of FALSE.
704a4b75 212
559fe022 213\membersection{wxHtmlWinParser::SetFontFixed}\label{wxhtmlwinparsersetfontfixed}
704a4b75 214
559fe022 215\func{void}{SetFontFixed}{\param{int }{x}}
704a4b75 216
559fe022 217Sets fixed face flag of actualfont. {\it x} is either TRUE of FALSE.
704a4b75 218
559fe022 219\membersection{wxHtmlWinParser::SetFontItalic}\label{wxhtmlwinparsersetfontitalic}
704a4b75 220
559fe022 221\func{void}{SetFontItalic}{\param{int }{x}}
704a4b75 222
559fe022 223Sets italic flag of actualfont. {\it x} is either TRUE of FALSE.
704a4b75 224
559fe022 225\membersection{wxHtmlWinParser::SetFontSize}\label{wxhtmlwinparsersetfontsize}
704a4b75 226
559fe022
VS
227\func{void}{SetFontSize}{\param{int }{s}}
228
229Sets actual font size (HTML size varies from -2 to +4)
230
231\membersection{wxHtmlWinParser::SetFontUnderlined}\label{wxhtmlwinparsersetfontunderlined}
232
233\func{void}{SetFontUnderlined}{\param{int }{x}}
234
235Sets underlined flag of actualfont. {\it x} is either TRUE of FALSE.
236
237\membersection{wxHtmlWinParser::SetFonts}\label{wxhtmlwinparsersetfonts}
704a4b75 238
559fe022
VS
239\func{void}{SetFonts}{\param{wxString }{normal\_face}, \param{int }{normal\_italic\_mode}, \param{wxString }{fixed\_face}, \param{int }{fixed\_italic\_mode}, \param{const int }{*sizes}}
240
241Sets fonts. This method is identical to \helpref{wxHtmlWindow::SetFonts}{wxhtmlwindowsetfonts}
704a4b75
VS
242
243\membersection{wxHtmlWinParser::SetLink}\label{wxhtmlwinparsersetlink}
244
245\func{void}{SetLink}{\param{const wxString\& }{link}}
246
247Sets actual hypertext link. wxEmptyString means no link.
248
559fe022 249\membersection{wxHtmlWinParser::SetLinkColor}\label{wxhtmlwinparsersetlinkcolor}
704a4b75 250
559fe022 251\func{void}{SetLinkColor}{\param{const wxColour\& }{clr}}
704a4b75 252
559fe022 253Sets color of hypertext link.
22d6efa8 254