X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/ce00f59b5b169752d2f05ce3bb1a88ddc1b38b4c..6eefca4fb7793a8d6bc02e69694735cb3e5fc230:/include/wx/dvrenderers.h diff --git a/include/wx/dvrenderers.h b/include/wx/dvrenderers.h index 248e4af121..1be414ffb7 100644 --- a/include/wx/dvrenderers.h +++ b/include/wx/dvrenderers.h @@ -118,6 +118,10 @@ public: wxString GetVariantType() const { return m_variantType; } + // helper that calls SetValue and SetAttr: + void PrepareForItem(const wxDataViewModel *model, + const wxDataViewItem& item, unsigned column); + // renderer properties: virtual void SetMode( wxDataViewCellMode mode ) = 0; virtual wxDataViewCellMode GetMode() const = 0; @@ -267,6 +271,10 @@ public: // Prepare DC to use attributes and call Render(). void WXCallRender(wxRect rect, wxDC *dc, int state); +protected: + // helper for GetSize() implementations, respects attributes + wxSize GetTextExtent(const wxString& str) const; + private: wxDataViewItemAttr m_attr;