]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/htmllbox.tex
changed the catalogs lookup back to the old behaviour of searching LC_MESSAGES subdir...
[wxWidgets.git] / docs / latex / wx / htmllbox.tex
CommitLineData
e0c6027b
VZ
1%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
2%% Name: htmllbox.tex
3%% Purpose: wxHtmlListBox documentation
4%% Author: Vadim Zeitlin
5%% Modified by:
6%% Created: 01.06.03
7%% RCS-ID: $Id$
8%% Copyright: (c) 2003 Vadim Zeitlin <vadim@wxwindows.org>
8795498c 9%% License: wxWindows license
e0c6027b
VZ
10%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
11
12\section{\class{wxHtmlListBox}}\label{wxhtmllistbox}
13
14wxHtmlListBox is an implementation of \helpref{wxVListBox}{wxvlistbox} which
15shows HTML content in the listbox rows. This is still an abstract base class
16and you will need to derive your own class from it (see htlbox sample for the
410bfc93 17example) but you will only need to override a single
e0c6027b
VZ
18\helpref{OnGetItem()}{wxhtmllistboxongetitem} function.
19
20\wxheading{Derived from}
21
410bfc93
WS
22\helpref{wxVListBox}{wxvlistbox}\\
23\helpref{wxVScrolledWindow}{wxvscrolledwindow}\\
24\helpref{wxPanel}{wxpanel}\\
25\helpref{wxWindow}{wxwindow}\\
26\helpref{wxEvtHandler}{wxevthandler}\\
27\helpref{wxObject}{wxobject}
e0c6027b
VZ
28
29\wxheading{Include files}
30
31<wx/htmllbox.h>
32
33
34\latexignore{\rtfignore{\wxheading{Members}}}
35
36
37\membersection{wxHtmlListBox::wxHtmlListBox}\label{wxhtmllistboxwxhtmllistbox}
38
9a1e758d 39\func{}{wxHtmlListBox}{\param{wxWindow* }{parent}, \param{wxWindowID }{id = wxID\_ANY}, \param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\& }{size = wxDefaultSize}, \param{long }{style = 0}, \param{const wxString\& }{name = wxVListBoxNameStr}}
e0c6027b
VZ
40
41Normal constructor which calls \helpref{Create()}{wxhtmllistboxcreate}
42internally.
43
44\func{}{wxHtmlListBox}{\void}
45
46Default constructor, you must call \helpref{Create()}{wxhtmllistboxcreate}
47later.
48
49
50\membersection{wxHtmlListBox::\destruct{wxHtmlListBox}}\label{wxhtmllistboxdtor}
51
52\func{}{\destruct{wxHtmlListBox}}{\void}
53
54Destructor cleans up whatever resources we use.
55
56
57\membersection{wxHtmlListBox::Create}\label{wxhtmllistboxcreate}
58
9a9b4940 59\func{bool}{Create}{\param{wxWindow* }{parent}, \param{wxWindowID }{id = wxID\_ANY}, \param{const wxPoint\& }{pos = wxDefaultPosition}, \param{const wxSize\& }{size = wxDefaultSize}, \param{long }{style = 0}, \param{const wxString\& }{name = wxVListBoxNameStr}}
e0c6027b
VZ
60
61Creates the control and optionally sets the initial number of items in it
410bfc93 62(it may also be set or changed later with
e0c6027b
VZ
63\helpref{SetItemCount()}{wxvlistboxsetitemcount}).
64
65There are no special styles defined for wxHtmlListBox, in particular the
66wxListBox styles can not be used here.
67
68Returns {\tt true} on success or {\tt false} if the control couldn't be created
69
70
2d814c19
VZ
71\membersection{wxHtmlListBox::GetFileSystem}\label{wxhtmllistboxgetfilesystem}
72
73\func{wxFileSystem\&}{GetFileSystem}{\void}
74
75\constfunc{const wxFileSystem\&}{GetFileSystem}{\void}
76
77Returns the \helpref{wxFileSystem}{wxfilesystem} used by the HTML parser of
78this object. The file system object is used to resolve the paths in HTML
410bfc93 79fragments displayed in the control and you should use
2d814c19
VZ
80\helpref{wxFileSystem::ChangePathTo}{wxfilesystemchangepathto} if you use
81relative paths for the images or other resources embedded in your HTML.
82
83
9a9b4940
VZ
84\membersection{wxHtmlListBox::GetSelectedTextBgColour}\label{wxhtmllistboxgetselectedtextbgcolour}
85
86\constfunc{wxColour}{GetSelectedTextBgColour}{\param{const wxColour\& }{colBg}}
87
88This virtual function may be overridden to change the appearance of the
410bfc93 89background of the selected cells in the same way as
9a9b4940
VZ
90\helpref{GetSelectedTextColour}{wxhtmllistboxgetselectedtextcolour}.
91
410bfc93 92It should be rarely, if ever, used because
9a9b4940
VZ
93\helpref{SetSelectionBackground}{wxvlistboxsetselectionbackground} allows to
94change the selection background for all cells at once and doing anything more
95fancy is probably going to look strangely.
96
97\wxheading{See also}
98
99\helpref{GetSelectedTextColour}{wxhtmllistboxgetselectedtextcolour}
100
101
102\membersection{wxHtmlListBox::GetSelectedTextColour}\label{wxhtmllistboxgetselectedtextcolour}
103
104\constfunc{wxColour}{GetSelectedTextColour}{\param{const wxColour\& }{colFg}}
105
106This virtual function may be overridden to customize the appearance of the
107selected cells. It is used to determine how the colour {\it colFg} is going to
108look inside selection. By default all original colours are completely ignored
109and the standard, system-dependent, selection colour is used but the program
110may wish to override this to achieve some custom appearance.
111
112\wxheading{See also}
113
114\helpref{GetSelectedTextBgColour}{wxhtmllistboxgetselectedtextbgcolour},\\
115\helpref{SetSelectionBackground}{wxvlistboxsetselectionbackground},\\
116\helpref{wxSystemSettings::GetColour}{wxsystemsettingsgetcolour}
117
e0c6027b
VZ
118
119\membersection{wxHtmlListBox::OnGetItem}\label{wxhtmllistboxongetitem}
120
121\constfunc{wxString}{OnGetItem}{\param{size\_t }{n}}
122
123This method must be implemented in the derived class and should return
124the body (i.e. without {\tt <html>} nor {\tt <body>} tags) of the HTML fragment
125for the given item.
126
127
128\membersection{wxHtmlListBox::OnGetItemMarkup}\label{wxhtmllistboxongetitemmarkup}
129
130\constfunc{wxString}{OnGetItemMarkup}{\param{size\_t }{n}}
131
132This function may be overridden to decorate HTML returned by
133\helpref{OnGetItem()}{wxhtmllistboxongetitem}.
134
bc55e31b
VS
135\membersection{wxHtmlListBox::OnLinkClicked}\label{wxhtmlistboxonlinkclicked}
136
137\func{virtual void}{OnLinkClicked}{\param{size\_t }{n}, \param{const wxHtmlLinkInfo\& }{link}}
138
139Called when the user clicks on hypertext link. Does nothing by default.
140
141\wxheading{Parameters}
142
143\docparam{n}{Index of the item containing the link.}
144
145\docparam{link}{Description of the link.}
146
147\wxheading{See also}
148
149See also \helpref{wxHtmlLinkInfo}{wxhtmllinkinfo}.