List box elements are numbered from zero.
A listbox callback gets an event wxEVT\_COMMAND\_LISTBOX\_SELECT for single clicks, and
-wxEVT\_COMMAND\_LISTBOX\_DOUBLE\_CLICKED for double clicks. Another way of intercepting
-double clicks is to override \helpref{wxWindow::OnDefaultAction}{wxwindowondefaultaction}.
+wxEVT\_COMMAND\_LISTBOX\_DOUBLE\_CLICKED for double clicks.
\wxheading{Derived from}
\helpref{wxEvtHandler}{wxevthandler}\\
\helpref{wxObject}{wxobject}
+\wxheading{Include files}
+
+<wx/listbox.h>
+
\wxheading{Window styles}
\twocolwidtha{5cm}%
See also \helpref{window styles overview}{windowstyles}.
+\wxheading{Event handling}
+
+\twocolwidtha{7cm}
+\begin{twocollist}\itemsep=0pt
+\twocolitem{{\bf EVT\_LISTBOX(id, func)}}{Process a wxEVT\_COMMAND\_LISTBOX\_SELECTED event,
+when an item on the list is selected.}
+\twocolitem{{\bf EVT\_LISTBOX\_DCLICK(id, func)}}{Process a wxEVT\_COMMAND\_LISTBOX\_DOUBLECLICKED event,
+when the listbox is doubleclicked.}
+\end{twocollist}
+
\wxheading{See also}
-\helpref{wxChoice}{wxchoice}, \helpref{wxComboBox}{wxcombobox}, \helpref{wxListCtrl}{wxlistctrl}
+\helpref{wxChoice}{wxchoice}, \helpref{wxComboBox}{wxcombobox}, \helpref{wxListCtrl}{wxlistctrl},
+\rtfsp\helpref{wxCommandEvent}{wxcommandevent}
\latexignore{\rtfignore{\wxheading{Members}}}
\helpref{wxListBox::Create}{wxlistboxcreate}, \helpref{wxValidator}{wxvalidator}
+\pythonnote{The wxListBox constructor in wxPython reduces the \tt{n}
+and \tt{choices} arguments are to a single argument, which is
+a list of strings.}
+
+
+
\membersection{wxListBox::\destruct{wxListBox}}
\func{void}{\destruct{wxListBox}}{\void}
\helpref{wxListBox::GetStringSelection}{wxlistboxgetstringselection},\rtfsp
\helpref{wxListBox::SetSelection}{wxlistboxsetselection}
+\pythonnote{The wxPython version of this method takes no parameters
+and returns a tuple of the selected items.}
+
\membersection{wxListBox::GetString}\label{wxlistboxgetstring}
\constfunc{wxString}{GetString}{\param{int}{ n}}
\helpref{wxListBox::GetSelections}{wxlistboxgetselections},\rtfsp
\helpref{wxListBox::SetSelection}{wxlistboxsetselection}
+\membersection{wxListBox::InsertItems}\label{wxlistboxinsertitems}
+
+\func{void}{InsertItems}{\param{int}{ nItems}, \param{const wxString}{ items}, \param{int}{ pos}}
+
+Insert the given number of strings before the specified position.
+
+\wxheading{Parameters}
+
+\docparam{nItems}{Number of items in the array {\it items}}
+
+\docparam{items}{Labels of items to be inserted}
+
+\docparam{pos}{Position before which to insert the items: for example, if {\it pos} is 0 the items
+will be inserted in the beginning of the listbox}
+
\membersection{wxListBox::Number}\label{wxlistboxnumber}
\constfunc{int}{Number}{\void}