1 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
3 %% Purpose: wxListView documentation
4 %% Author: Vadim Zeitlin
8 %% Copyright: (c) 2002 Vadim Zeitlin <vadim@wxwindows.org>
9 %% License: wxWindows license
10 %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
12 \section{\class{wxListView
}}\label{wxlistview
}
14 This class currently simply presents a simpler to use interface for the
15 \helpref{wxListCtrl
}{wxlistctrl
} -- it can be thought of as a
{\it fa
\c{c
}ade
}
16 for that complicated class. Using it is preferable to using
17 \helpref{wxListCtrl
}{wxlistctrl
} directly whenever possible because in the
18 future some ports might implement wxListView but not the full set of wxListCtrl
21 Other than different interface, this class is identical to wxListCtrl. In
22 particular, it uses the same events, same window styles and so on.
24 \wxheading{Derived from
}
26 \helpref{wxListCtrl
}{wxlistctrl
}\\
27 \helpref{wxControl
}{wxcontrol
}\\
28 \helpref{wxWindow
}{wxwindow
}\\
29 \helpref{wxEvtHandler
}{wxevthandler
}\\
30 \helpref{wxObject
}{wxobject
}
32 \wxheading{Include files
}
38 \helpref{wxCore
}{librarieslist
}
40 %%%%%%%%%%%%% Methods in alphabetic order %%%%%%%%%%%%%
41 \latexignore{\rtfignore{\wxheading{Members
}}}
43 \membersection{wxListView::ClearColumnImage
}\label{wxlistviewclearcolumnimage
}
45 \func{void
}{ClearColumnImage
}{\param{int
}{col
}}
47 Resets the column image -- after calling this function, no image will be shown.
49 \wxheading{Parameters
}
51 \docparam{col
}{the column to clear image for
}
55 \helpref{SetColumnImage
}{wxlistviewsetcolumnimage
}
58 \membersection{wxListView::Focus
}\label{wxlistviewfocus
}
60 \func{void
}{Focus
}{\param{long
}{index
}}
62 Sets focus to the item with the given
{\it index
}.
65 \membersection{wxListView::GetFirstSelected
}\label{wxlistviewgetfirstselected
}
67 \constfunc{long
}{GetFirstSelected
}{\void}
69 Returns the first selected item in a (presumably) multiple selection control.
70 Together with
\helpref{GetNextSelected
}{wxlistviewgetnextselected
} it can be
71 used to iterate over all selected items in the control.
73 \wxheading{Return value
}
75 The first selected item, if any, $-
1$ otherwise.
78 \membersection{wxListView::GetFocusedItem
}\label{wxlistviewgetfocuseditem
}
80 \constfunc{long
}{GetFocusedItem
}{\void}
82 Returns the currently focused item or $-
1$ if none.
86 \helpref{IsSelected
}{wxlistviewisselected
},\\
87 \helpref{Focus
}{wxlistviewfocus
}
90 \membersection{wxListView::GetNextSelected
}\label{wxlistviewgetnextselected
}
92 \constfunc{long
}{GetNextSelected
}{\param{long
}{item
}}
94 Used together with
\helpref{GetFirstSelected
}{wxlistviewgetfirstselected
} to
95 iterate over all selected items in the control.
97 \wxheading{Return value
}
99 Returns the next selected item or $-
1$ if there are no more of them.
102 \membersection{wxListView::IsSelected
}\label{wxlistviewisselected
}
104 \constfunc{bool
}{IsSelected
}{\param{long
}{index
}}
106 Returns
{\tt true
} if the item with the given
{\it index
} is selected,
107 {\tt false
} otherwise.
111 \helpref{GetFirstSelected
}{wxlistviewgetfirstselected
},\\
112 \helpref{GetNextSelected
}{wxlistviewgetnextselected
}
115 \membersection{wxListView::Select
}\label{wxlistviewselect
}
117 \func{void
}{Select
}{long n,
\param{bool
}{on = true
}}
119 Selects or unselects the given item.
121 \wxheading{Parameters
}
123 \docparam{n
}{the item to select or unselect
}
125 \docparam{on
}{if
{\tt true
} (default), selects the item, otherwise unselects it
}
129 \helpref{SetItemState
}{wxlistctrlsetitemstate
}
132 \membersection{wxListView::SetColumnImage
}\label{wxlistviewsetcolumnimage
}
134 \func{void
}{SetColumnImage
}{\param{int
}{col
},
\param{int
}{image
}}
136 Sets the column image for the specified column. To use the column images, the
137 control must have a valid image list with at least one image.
139 \wxheading{Parameters
}
141 \docparam{col
}{the column to set image for
}
143 \docparam{image
}{the index of the column image in the controls image list
}
147 \helpref{ClearColumnImage
}{wxlistviewclearcolumnimage
},\\
148 \helpref{SetImageList
}{wxlistctrlsetimagelist
}