]> git.saurik.com Git - wxWidgets.git/blobdiff - include/wx/cocoa/font.h
Make wxRichTextRectArray usable by other parts of wxRTC
[wxWidgets.git] / include / wx / cocoa / font.h
index b671f95bcb61a96792fe120f11529eabb262f344..c9c245f9e1e7eaabd13795d3bd3d358acb6128f8 100644 (file)
@@ -1,10 +1,9 @@
 /////////////////////////////////////////////////////////////////////////////
-// Name:        font.h
+// Name:        wx/cocoa/font.h
 // Purpose:     wxFont class
 // Author:      Julian Smart
 // Modified by:
 // Created:     01/02/97
-// RCS-ID:      $Id$
 // Copyright:   (c) Julian Smart
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
@@ -38,6 +37,20 @@ 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());
+    }
+
     /*! @abstract   Platform-independent construction with individual properties
      */
 #if FUTURE_WXWIN_COMPATIBILITY_3_0