]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/x11/font.h
Applied rowspan patch #15276 (dghart)
[wxWidgets.git] / include / wx / x11 / font.h
index a7197b878b4d10c8ef6c19279425fdbf46c17d94..f05177a46dae0631029de6b817fd94dfdf5d1463 100644 (file)
@@ -21,6 +21,20 @@ public:
     // ctors and such
     wxFont() { }
 
     // ctors and such
     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());
+    }
+
 #if FUTURE_WXWIN_COMPATIBILITY_3_0
     wxFont(int size,
            int family,
 #if FUTURE_WXWIN_COMPATIBILITY_3_0
     wxFont(int size,
            int family,
@@ -80,7 +94,6 @@ public:
 
     // implement base class pure virtuals
     virtual int GetPointSize() const;
 
     // implement base class pure virtuals
     virtual int GetPointSize() const;
-    virtual wxFontFamily GetFamily() const;
     virtual wxFontStyle GetStyle() const;
     virtual wxFontWeight GetWeight() const;
     virtual bool GetUnderlined() const;
     virtual wxFontStyle GetStyle() const;
     virtual wxFontWeight GetWeight() const;
     virtual bool GetUnderlined() const;
@@ -129,6 +142,7 @@ protected:
     virtual wxGDIRefData *CloneGDIRefData(const wxGDIRefData *data) const;
 
     virtual void DoSetNativeFontInfo( const wxNativeFontInfo& info );
     virtual wxGDIRefData *CloneGDIRefData(const wxGDIRefData *data) const;
 
     virtual void DoSetNativeFontInfo( const wxNativeFontInfo& info );
+    virtual wxFontFamily DoGetFamily() const;
 
     void Unshare();
 
 
     void Unshare();