]> git.saurik.com Git - wxWidgets.git/blobdiff - src/mgl/font.cpp
fixed loop deleting the old filters in SetWildcard() after last commit
[wxWidgets.git] / src / mgl / font.cpp
index b6d93684c166ffdd22bbf262e314f1cfe481306d..06d972feeeba94d652d1636b6f04712f97fb2176 100644 (file)
@@ -2,7 +2,7 @@
 // Name:        font.cpp
 // Author:      Vaclav Slavik
 // Id:          $Id$
-// Copyright:   (c) 2001 SciTech Software, Inc. (www.scitechsoft.com)
+// Copyright:   (c) 2001-2002 SciTech Software, Inc. (www.scitechsoft.com)
 // Licence:     wxWindows licence
 /////////////////////////////////////////////////////////////////////////////
 
@@ -14,7 +14,7 @@
 // headers
 // ----------------------------------------------------------------------------
 
-#ifdef __GNUG__
+#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
     #pragma implementation "font.h"
 #endif
 
@@ -74,6 +74,8 @@ private:
     wxMGLFontLibrary *m_library;
     bool              m_valid;
 
+    wxNativeFontInfo  m_info;
+
     friend class wxFont;
 };
 
@@ -264,6 +266,14 @@ bool wxFont::IsFixedWidth() const
     return (bool)(M_FONTDATA->m_library->GetFamily()->GetInfo()->isFixed);
 }
 
+const wxNativeFontInfo *wxFont::GetNativeFontInfo() const
+{
+    wxCHECK_MSG( Ok(), NULL, wxT("invalid font") );
+
+    M_FONTDATA->m_info.InitFromFont(*this);
+
+    return &(M_FONTDATA->m_info);
+}
 
 // ----------------------------------------------------------------------------
 // change font attributes