X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f76c075805027058f08ffba0e8c1b32372f5fd44..a4301b8f14d21b7d28fc4f6a247b740d945ca6dc:/include/wx/dfb/font.h diff --git a/include/wx/dfb/font.h b/include/wx/dfb/font.h index def7085e07..db68dbd3ff 100644 --- a/include/wx/dfb/font.h +++ b/include/wx/dfb/font.h @@ -23,6 +23,21 @@ class WXDLLIMPEXP_CORE wxFont : public wxFontBase { public: wxFont() {} + + wxFont(const wxFontInfo& info) + { + Create(info.GetPointSize(), + info.GetFamily(), + info.GetStyle(), + info.GetWeight(), + info.IsUnderlined(), + info.GetFaceName(), + info.GetEncoding()); + + if ( info.IsUsingSizeInPixels() ) + SetPixelSize(info.GetPixelSize()); + } + wxFont(const wxNativeFontInfo& info) { Create(info); } #if FUTURE_WXWIN_COMPATIBILITY_3_0 wxFont(int size, @@ -47,7 +62,7 @@ public: { Create(size, family, style, weight, underlined, face, encoding); } - + wxFont(const wxSize& pixelSize, wxFontFamily family, wxFontStyle style, @@ -59,7 +74,7 @@ public: Create(10, family, style, weight, underlined, face, encoding); SetPixelSize(pixelSize); } - + bool Create(int size, wxFontFamily family, wxFontStyle style, @@ -71,7 +86,6 @@ public: // implement base class pure virtuals virtual int GetPointSize() const; - virtual wxFontFamily GetFamily() const; virtual wxFontStyle GetStyle() const; virtual wxFontWeight GetWeight() const; virtual wxString GetFaceName() const; @@ -90,10 +104,6 @@ public: wxDECLARE_COMMON_FONT_METHODS(); - // Unofficial API, don't use - virtual void SetNoAntiAliasing(bool no = true); - virtual bool GetNoAntiAliasing() const; - // implementation from now on: wxIDirectFBFontPtr GetDirectFBFont(bool antialiased) const; @@ -101,6 +111,8 @@ protected: virtual wxGDIRefData *CreateGDIRefData() const; virtual wxGDIRefData *CloneGDIRefData(const wxGDIRefData *data) const; + virtual wxFontFamily DoGetFamily() const; + private: DECLARE_DYNAMIC_CLASS(wxFont) };