X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f516d986371b7643efda569d64ae19e75d221411..74b720793f9d312566450461fac394e5e456ae5d:/include/wx/gdicmn.h diff --git a/include/wx/gdicmn.h b/include/wx/gdicmn.h index fd6d6c2543..b1e5d72c18 100644 --- a/include/wx/gdicmn.h +++ b/include/wx/gdicmn.h @@ -452,40 +452,46 @@ public: typedef wxInt8 wxDash; -class WXDLLEXPORT wxPenList : public wxList -{ +class WXDLLIMPEXP_CORE wxGDIObjListBase { public: - wxPenList() { } - ~wxPenList(); + wxGDIObjListBase(); + ~wxGDIObjListBase(); - void AddPen(wxPen *pen); - void RemovePen(wxPen *pen); - wxPen *FindOrCreatePen(const wxColour& colour, int width, int style); +protected: + wxList list; }; -class WXDLLEXPORT wxBrushList : public wxList +class WXDLLIMPEXP_CORE wxPenList: public wxGDIObjListBase { public: - wxBrushList() { } - ~wxBrushList(); + wxPen *FindOrCreatePen(const wxColour& colour, int width, int style); +#if WXWIN_COMPATIBILITY_2_6 + wxDEPRECATED( void AddPen(wxPen*) ); + wxDEPRECATED( void RemovePen(wxPen*) ); +#endif +}; - void AddBrush(wxBrush *brush); - void RemoveBrush(wxBrush *brush); +class WXDLLIMPEXP_CORE wxBrushList: public wxGDIObjListBase +{ +public: wxBrush *FindOrCreateBrush(const wxColour& colour, int style = wxSOLID); +#if WXWIN_COMPATIBILITY_2_6 + wxDEPRECATED( void AddBrush(wxBrush*) ); + wxDEPRECATED( void RemoveBrush(wxBrush*) ); +#endif }; -class WXDLLEXPORT wxFontList : public wxList +class WXDLLIMPEXP_CORE wxFontList: public wxGDIObjListBase { public: - wxFontList() { } - ~wxFontList(); - - void AddFont(wxFont *font); - void RemoveFont(wxFont *font); wxFont *FindOrCreateFont(int pointSize, int family, int style, int weight, bool underline = false, const wxString& face = wxEmptyString, wxFontEncoding encoding = wxFONTENCODING_DEFAULT); +#if WXWIN_COMPATIBILITY_2_6 + wxDEPRECATED( void AddFont(wxFont*) ); + wxDEPRECATED( void RemoveFont(wxFont*) ); +#endif }; WX_DECLARE_STRING_HASH_MAP( wxColour *, wxStringToColourHashMap ); @@ -523,16 +529,6 @@ private: wxStringToColourHashMap *m_map; }; -class WXDLLEXPORT wxBitmapList : public wxList -{ -public: - wxBitmapList(){} - ~wxBitmapList(); - - void AddBitmap(wxBitmap *bitmap); - void RemoveBitmap(wxBitmap *bitmap); -}; - class WXDLLEXPORT wxResourceCache: public wxList { public: @@ -551,7 +547,6 @@ public: extern WXDLLEXPORT_DATA(wxPenList*) wxThePenList; extern WXDLLEXPORT_DATA(wxBrushList*) wxTheBrushList; extern WXDLLEXPORT_DATA(wxFontList*) wxTheFontList; -extern WXDLLEXPORT_DATA(wxBitmapList*) wxTheBitmapList; /* Stock objects