2 \section{\class{wxDataViewIndexListModel
}}\label{wxdataviewindexlistmodel
}
4 wxDataViewIndexListModel is a specialized data model which lets
5 you address an item by its position (row) rather than its
6 wxDataViewItem (which you can obtain from this class).
7 This model also provides its own
8 \helpref{Compare
}{wxdataviewindexlistmodelcompare
} method
9 which sorts the model's data by the index.
12 \wxheading{Derived from
}
14 \helpref{wxDataViewModel
}{wxdataviewmodel
}
16 \wxheading{Include files
}
20 \latexignore{\rtfignore{\wxheading{Members
}}}
23 \membersection{wxDataViewIndexListModel::wxDataViewIndexListModel
}\label{wxdataviewindexlistmodelwxdataviewindexlistmodel
}
25 \func{}{wxDataViewIndexListModel
}{\param{unsigned int
}{initial
\_size =
0}}
29 \membersection{wxDataViewIndexListModel::
\destruct{wxDataViewIndexListModel
}}\label{wxdataviewindexlistmodeldtor
}
31 \func{}{\destruct{wxDataViewIndexListModel
}}{\void}
35 \membersection{wxDataViewIndexListModel::Compare
}\label{wxdataviewindexlistmodelcompare
}
37 \func{int
}{Compare
}{\param{const wxDataViewItem\&
}{item1
},
\param{const wxDataViewItem\&
}{item2
},
\param{unsigned int
}{column
},
\param{bool
}{ascending
}}
39 Compare method that sorts the items by their index.
41 \membersection{wxDataViewIndexListModel::GetAttr
}\label{wxdataviewindexlistmodelgetattr
}
43 \func{bool
}{GetAttr
}{\param{unsigned int
}{row
},
\param{unsigned int
}{col
},
\param{wxDataViewItemAttr\&
}{attr
}}
45 Oberride this to indicate that the row has special font attributes.
47 \helpref{wxDataViewTextRendererText
}{wxdataviewtextrendererattr
} renderer.
49 See also
\helpref{wxDataViewItemAttr
}{wxdataviewitemattr
}.
51 \membersection{wxDataViewIndexListModel::GetItem
}\label{wxdataviewindexlistmodelgetitem
}
53 \constfunc{wxDataViewItem
}{GetItem
}{\param{unsigned int
}{row
}}
55 Returns the wxDataViewItem at the given
{\it row
}.
57 \membersection{wxDataViewIndexListModel::GetRow
}\label{wxdataviewindexlistmodelgetrow
}
59 \constfunc{unsigned int
}{GetRow
}{\param{const wxDataViewItem\&
}{item
}}
61 Returns the position of given
{\it item
}.
63 \membersection{wxDataViewIndexListModel::GetValue
}\label{wxdataviewindexlistmodelgetvalue
}
65 \constfunc{void
}{GetValue
}{\param{wxVariant\&
}{variant
},
\param{unsigned int
}{row
},
\param{unsigned int
}{col
}}
67 Override this to allow getting values from the model.
69 \membersection{wxDataViewIndexListModel::RowAppended
}\label{wxdataviewindexlistmodelrowappended
}
71 \func{void
}{RowAppended
}{\void}
73 Call this after a row has been appended to the model.
75 \membersection{wxDataViewIndexListModel::RowChanged
}\label{wxdataviewindexlistmodelrowchanged
}
77 \func{void
}{RowChanged
}{\param{unsigned int
}{row
}}
79 Call this after a row has been changed.
81 \membersection{wxDataViewIndexListModel::RowDeleted
}\label{wxdataviewindexlistmodelrowdeleted
}
83 \func{void
}{RowDeleted
}{\param{unsigned int
}{row
}}
85 Call this after a row has been deleted.
87 \membersection{wxDataViewIndexListModel::RowInserted
}\label{wxdataviewindexlistmodelrowinserted
}
89 \func{void
}{RowInserted
}{\param{unsigned int
}{before
}}
91 Call this after a row has been inserted at the given position.
93 \membersection{wxDataViewIndexListModel::RowPrepended
}\label{wxdataviewindexlistmodelrowprepended
}
95 \func{void
}{RowPrepended
}{\void}
97 Call this after a row has been prepended to the model.
99 \membersection{wxDataViewIndexListModel::RowValueChanged
}\label{wxdataviewindexlistmodelrowvaluechanged
}
101 \func{void
}{RowValueChanged
}{\param{unsigned int
}{row
},
\param{unsigned int
}{col
}}
103 Call this after a value has been changed.
105 \membersection{wxDataViewIndexListModel::SetValue
}\label{wxdataviewindexlistmodelsetvalue
}
107 \func{bool
}{SetValue
}{\param{const wxVariant\&
}{variant
},
\param{unsigned int
}{row
},
\param{unsigned int
}{col
}}
109 Called in order to set a value in the model.