X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/98ec9dbebc5584ba1b903d314b25e8c562891483..3f0fb1d4165f622ab392a28c1a08a975aa7c5378:/include/wx/msw/listctrl.h diff --git a/include/wx/msw/listctrl.h b/include/wx/msw/listctrl.h index e11e89c670..2bce95d808 100644 --- a/include/wx/msw/listctrl.h +++ b/include/wx/msw/listctrl.h @@ -21,8 +21,9 @@ #include "wx/control.h" #include "wx/event.h" #include "wx/hash.h" +#include "wx/textctrl.h" + -class WXDLLEXPORT wxTextCtrl; class WXDLLEXPORT wxImageList; /* @@ -190,6 +191,14 @@ public: // view, otherwise the large icon view. int GetItemSpacing(bool isSmall) const; + // Foreground colour of an item. + void SetItemTextColour( long item, const wxColour& col); + wxColour GetItemTextColour( long item ) const; + + // Background colour of an item. + void SetItemBackgroundColour( long item, const wxColour &col); + wxColour GetItemBackgroundColour( long item ) const; + // Gets the number of selected items in the list control int GetSelectedItemCount() const; @@ -231,6 +240,10 @@ public: // returns true if it is a virtual list control bool IsVirtual() const { return (GetWindowStyle() & wxLC_VIRTUAL) != 0; } + // refresh items selectively (only useful for virtual list controls) + void RefreshItem(long item); + void RefreshItems(long itemFrom, long itemTo); + // Operations //////////////////////////////////////////////////////////////////////////// @@ -373,9 +386,15 @@ protected: // return the icon for the given item virtual int OnGetItemImage(long item) const; + // return the attribute for the item (may return NULL if none) + virtual wxListItemAttr *OnGetItemAttr(long item) const; + private: bool DoCreateControl(int x, int y, int w, int h); + // process NM_CUSTOMDRAW notification message + WXLPARAM OnCustomDraw(WXLPARAM lParam); + DECLARE_DYNAMIC_CLASS(wxListCtrl) DECLARE_EVENT_TABLE() }; @@ -384,3 +403,5 @@ private: #endif // _WX_LISTCTRL_H_ + +// vi:sts=4:sw=4:et