]> git.saurik.com Git - wxWidgets.git/blame - interface/checklst.h
don't style using Doxygen tags; use <span> tags and CSS instead
[wxWidgets.git] / interface / checklst.h
CommitLineData
23324ae1
FM
1/////////////////////////////////////////////////////////////////////////////
2// Name: checklst.h
3// Purpose: documentation for wxCheckListBox class
4// Author: wxWidgets team
5// RCS-ID: $Id$
6// Licence: wxWindows license
7/////////////////////////////////////////////////////////////////////////////
8
9/**
10 @class wxCheckListBox
11 @wxheader{checklst.h}
7c913512 12
23324ae1 13 A checklistbox is like a listbox, but allows items to be checked or unchecked.
7c913512 14
23324ae1
FM
15 When using this class under Windows wxWidgets must be compiled with
16 USE_OWNER_DRAWN set to 1.
7c913512 17
23324ae1 18 Only the new functions for this class are documented; see also wxListBox.
7c913512 19
23324ae1
FM
20 Please note that wxCheckListBox uses client data in its implementation,
21 and therefore this is not available to the application.
7c913512 22
23324ae1
FM
23 @beginEventTable
24 @event{EVT_CHECKLISTBOX(id\, func)}:
25 Process a wxEVT_COMMAND_CHECKLISTBOX_TOGGLED event, when an item in
26 the check list box is checked or unchecked.
27 @endEventTable
7c913512 28
23324ae1
FM
29 @library{wxcore}
30 @category{ctrl}
31 @appearance{checklistbox.png}
7c913512 32
23324ae1
FM
33 @seealso
34 wxListBox, wxChoice, wxComboBox, wxListCtrl, wxCommandEvent
35*/
36class wxCheckListBox : public wxListBox
37{
38public:
39 //@{
40 /**
41 Constructor, creating and showing a list box.
42
7c913512 43 @param parent
23324ae1
FM
44 Parent window. Must not be @NULL.
45
7c913512 46 @param id
23324ae1
FM
47 Window identifier. The value wxID_ANY indicates a default value.
48
7c913512 49 @param pos
23324ae1
FM
50 Window position.
51
7c913512 52 @param size
23324ae1
FM
53 Window size. If wxDefaultSize is specified then the window is sized
54 appropriately.
55
7c913512 56 @param n
23324ae1
FM
57 Number of strings with which to initialise the control.
58
7c913512 59 @param choices
23324ae1
FM
60 An array of strings with which to initialise the control.
61
7c913512 62 @param style
23324ae1
FM
63 Window style. See wxCheckListBox.
64
7c913512 65 @param validator
23324ae1
FM
66 Window validator.
67
7c913512 68 @param name
23324ae1
FM
69 Window name.
70 */
71 wxCheckListBox();
7c913512
FM
72 wxCheckListBox(wxWindow* parent, wxWindowID id,
73 const wxPoint& pos = wxDefaultPosition,
74 const wxSize& size = wxDefaultSize,
75 int n,
76 const wxString choices[] = @NULL,
77 long style = 0,
78 const wxValidator& validator = wxDefaultValidator,
79 const wxString& name = "listBox");
80 wxCheckListBox(wxWindow* parent, wxWindowID id,
81 const wxPoint& pos,
82 const wxSize& size,
83 const wxArrayString& choices,
84 long style = 0,
85 const wxValidator& validator = wxDefaultValidator,
86 const wxString& name = "listBox");
23324ae1
FM
87 //@}
88
89 /**
90 Destructor, destroying the list box.
91 */
92 ~wxCheckListBox();
93
94 /**
95 Checks the given item. Note that calling this method doesn't result in
96 wxEVT_COMMAND_CHECKLISTBOX_TOGGLE being emitted.
97
7c913512 98 @param item
23324ae1
FM
99 Index of item to check.
100
7c913512 101 @param check
23324ae1
FM
102 @true if the item is to be checked, @false otherwise.
103 */
104 void Check(int item, bool check = @true);
105};