]> git.saurik.com Git - wxWidgets.git/blob - docs/latex/wx/httaghnd.tex
added frame icon for HTMLhelp frame
[wxWidgets.git] / docs / latex / wx / httaghnd.tex
1 %
2 % automatically generated by HelpGen from
3 % htmltaghandler.tex at 18/Mar/99 19:20:29
4 %
5
6 \section{\class{wxHtmlTagHandler}}\label{wxhtmltaghandler}
7
8 \wxheading{Derived from}
9
10 wxObject
11
12 \wxheading{See Also}
13
14 \helpref{Overview}{handlers},
15 \helpref{wxHtmlTag}{wxhtmltag}
16
17 \latexignore{\rtfignore{\wxheading{Members}}}
18
19 \membersection{wxHtmlTagHandler::m\_Parser}\label{wxhtmltaghandlermparser}
20
21 {\bf wxHtmlParser* m\_Parser}
22
23 This attribute is used to access parent parser. It is protected so that
24 it can't be accessed by user but can be accessed from derived classes.
25
26 \membersection{wxHtmlTagHandler::wxHtmlTagHandler}\label{wxhtmltaghandlerwxhtmltaghandler}
27
28 \func{}{wxHtmlTagHandler}{\void}
29
30 Constructor.
31
32 \membersection{wxHtmlTagHandler::GetSupportedTags}\label{wxhtmltaghandlergetsupportedtags}
33
34 \func{virtual wxString}{GetSupportedTags}{\void}
35
36 Returns list of supported tags. The list is in uppercase and tags
37 are delimited by ','. Example : {\tt "I,B,FONT,P" }
38
39 \membersection{wxHtmlTagHandler::HandleTag}\label{wxhtmltaghandlerhandletag}
40
41 \func{virtual bool}{HandleTag}{\param{const wxHtmlTag\& }{tag}}
42
43 This is the core method of each handler. It is called each time
44 one of supported tags is detected. {\it tag} contains all neccessary
45 info (see \helpref{wxHtmlTag}{wxhtmltag} for details).
46
47 \wxheading{Return value}
48
49 TRUE if \helpref{ParseInner}{wxhtmltaghandlerparseinner} was called,
50 FALSE otherwise.
51
52 \wxheading{Example}
53
54 \begin{verbatim}
55 bool MyHandler::HandleTag(const wxHtmlTag& tag)
56 {
57 ...
58 // change state of parser (e.g. set bold face)
59 ParseInner(tag);
60 ...
61 // restore original state of parser
62 }
63 \end{verbatim}
64
65 You shouldn't call ParseInner if the tag is not paired with ending one.
66
67 \membersection{wxHtmlTagHandler::ParseInner}\label{wxhtmltaghandlerparseinner}
68
69 \func{void}{ParseInner}{\param{const wxHtmlTag\& }{tag}}
70
71 This method calls parser's \helpref{DoParsing}{wxhtmlparserdoparsing} method
72 for the string between this tag and paired ending tag:
73
74 \begin{verbatim}
75 ...<A HREF="x.htm">Hello, world!</A>...
76 \end{verbatim}
77
78 In this example, a call to ParseInner (with {\it tag} pointing to A tag)
79 will parse 'Hello, world!'.
80
81 \membersection{wxHtmlTagHandler::SetParser}\label{wxhtmltaghandlersetparser}
82
83 \func{virtual void}{SetParser}{\param{wxHtmlParser }{*parser}}
84
85 Assigns {\it parser} to this handler. Each {\bf instance} of handler
86 is guaranteed to be called only from the parser.
87