+\membersection{wxTreeCtrl::OnCompareItems}\label{wxtreectrloncompareitems}
+
+\func{int}{OnCompareItems}{\param{const wxTreeItemId\& }{item1}, \param{const wxTreeItemId\& }{item2}}
+
+Override this function in the derived class to change the sort order of the
+items in the tree control. The function should return a negative, zero or
+positive value if the first item is less than, equal to or greater than the
+second one.
+
+The base class version compares items alphabetically.
+
+See also: \helpref{SortChildren}{wxtreectrlsortchildren}
+