]> git.saurik.com Git - wxWidgets.git/blob - docs/latex/wx/dataviewcolumn.tex
Patches-1851591 ] dataview sample is crashing (under MSW)
[wxWidgets.git] / docs / latex / wx / dataviewcolumn.tex
1
2 \section{\class{wxDataViewColumn}}\label{wxdataviewcolumn}
3
4
5 This class represents a column in a \helpref{wxDataViewCtrl}{wxdataviewctrl}.
6 One wxDataViewColumn is bound to one column in the data model,
7 to which the wxDataViewCtrl has been associated.
8
9 An instance of \helpref{wxDataViewRenderer}{wxdataviewrenderer} is used by
10 this class to render its data.
11
12 \wxheading{Constants}
13
14 These flags define behaviour of the column:
15
16 {\small
17 \begin{verbatim}
18 enum wxDataViewColumnFlags
19 {
20 wxDATAVIEW_COL_RESIZABLE = 1, // the user can resize the column
21 wxDATAVIEW_COL_SORTABLE = 2, // same as SetSortable()
22 wxDATAVIEW_COL_HIDDEN = 4 // column is hidden
23 };
24 \end{verbatim}
25 }
26
27 \wxheading{Derived from}
28
29 \helpref{wxObject}{wxobject}
30
31 \wxheading{Include files}
32
33 <wx/dataview.h>
34
35 \wxheading{Library}
36
37 \helpref{wxAdv}{librarieslist}
38
39
40 \latexignore{\rtfignore{\wxheading{Members}}}
41
42 \membersection{wxDataViewColumn::wxDataViewColumn}\label{wxdataviewcolumnwxdataviewcolumn}
43
44 \func{}{wxDataViewColumn}{\param{const wxString\& }{title}, \param{wxDataViewRenderer* }{renderer}, \param{unsigned int }{model\_column}, \param{int }{width = wxDVC\_DEFAULT\_WIDTH}, \param{wxAlignment }{align = wxALIGN\_CENTRE}, \param{int }{flags = wxDATAVIEW\_COL\_RESIZABLE}}
45
46 \func{}{wxDataViewColumn}{\param{const wxBitmap\& }{bitmap}, \param{wxDataViewRenderer* }{renderer}, \param{unsigned int }{model\_column}, \param{int }{width = wxDVC\_DEFAULT\_WIDTH}, \param{wxAlignment }{align = wxALIGN\_CENTRE}, \param{int }{flags = wxDATAVIEW\_COL\_RESIZABLE}}
47
48 Constructors.
49
50
51 \membersection{wxDataViewColumn::\destruct{wxDataViewColumn}}\label{wxdataviewcolumndtor}
52
53 \func{}{\destruct{wxDataViewColumn}}{\void}
54
55 Destructor.
56
57 \membersection{wxDataViewColumn::GetBitmap}\label{wxdataviewcolumngetbitmap}
58
59 \func{const wxBitmap\&}{GetBitmap}{\void}
60
61 Returns the bitmap in the header of the column, if any.
62
63 \membersection{wxDataViewColumn::GetModelColumn}\label{wxdataviewcolumngetmodelcolumn}
64
65 \func{unsigned int}{GetModelColumn}{\void}
66
67 Returns the index of the column of the model, which this
68 wxDataViewColumn is displaying.
69
70 \membersection{wxDataViewColumn::GetOwner}\label{wxdataviewcolumngetowner}
71
72 \func{wxDataViewCtrl*}{GetOwner}{\void}
73
74 Returns the owning \helpref{wxDataViewCtrl}{wxdataviewctrl}.
75
76 \membersection{wxDataViewColumn::GetRenderer}\label{wxdataviewcolumngetrenderer}
77
78 \func{wxDataViewRenderer*}{GetRenderer}{\void}
79
80 Returns the renderer of this wxDataViewColumn.
81
82 See also \helpref{wxDataViewRenderer}{wxdataviewrenderer}.
83
84 \membersection{wxDataViewColumn::GetSortable}\label{wxdataviewcolumngetsortable}
85
86 \func{bool}{GetSortable}{\void}
87
88 Returns true if the column is sortable.
89
90 See \helpref{SetSortable}{wxdataviewcolumnsetsortable}
91
92 \membersection{wxDataViewColumn::GetWidth}\label{wxdataviewcolumngetwidth}
93
94 \func{int}{GetWidth}{\void}
95
96 Returns the width of the column.
97
98 \membersection{wxDataViewColumn::IsSortOrderAscending}\label{wxdataviewcolumnissortorderascending}
99
100 \func{bool}{IsSortOrderAscending}{\void}
101
102 Returns true, if the sort order is ascending.
103
104 See also \helpref{SetSortOrder}{wxdataviewcolumnsetsortorder}
105
106 \membersection{wxDataViewColumn::SetAlignment}\label{wxdataviewcolumnsetalignment}
107
108 \func{void}{SetAlignment}{\param{wxAlignment }{align}}
109
110 Set the alignment of the column header.
111
112 \membersection{wxDataViewColumn::SetBitmap}\label{wxdataviewcolumnsetbitmap}
113
114 \func{void}{SetBitmap}{\param{const wxBitmap\& }{bitmap}}
115
116 Set the bitmap of the column header.
117
118 \membersection{wxDataViewColumn::SetSortOrder}\label{wxdataviewcolumnsetsortorder}
119
120 \func{void}{SetSortOrder}{\param{bool }{ascending}}
121
122 Indicate the sort order if the implementation of the
123 wxDataViewCtrl supports it, most commonly by showing
124 a little arrow.
125
126 \membersection{wxDataViewColumn::SetSortable}\label{wxdataviewcolumnsetsortable}
127
128 \func{void}{SetSortable}{\param{bool }{sortable}}
129
130 Indicate that the column is sortable. This does
131 not show any sorting indicate yet, but it does
132 make the column header clickable. Call
133 \helpref{SetSortOrder}{wxdataviewcolumnsetsortorder}
134 afterwards to actually make the sort indicator appear.
135 If {\it sortable} is false, the column header is
136 no longer clickable and the sort indicator (little
137 arrow) will disappear.
138
139 \membersection{wxDataViewColumn::SetTitle}\label{wxdataviewcolumnsettitle}
140
141 \func{void}{SetTitle}{\param{const wxString\& }{title}}
142
143 Set the title of the column header to {\it title}.
144