]> git.saurik.com Git - wxWidgets.git/blobdiff - src/msw/font.cpp
Modified wxGetHomeDir to take environment variable HOME into account.
[wxWidgets.git] / src / msw / font.cpp
index ec02cd8ce43a91fbb7e768cd44422a6a2f0ba3e5..ae8752a780e12781b71d8d9ad6e25e1544046be9 100644 (file)
@@ -35,6 +35,7 @@
     #include "wx/app.h"
     #include "wx/font.h"
     #include "wx/log.h"
     #include "wx/app.h"
     #include "wx/font.h"
     #include "wx/log.h"
+    #include "wx/encinfo.h"
 #endif // WX_PRECOMP
 
 #include "wx/msw/private.h"
 #endif // WX_PRECOMP
 
 #include "wx/msw/private.h"
@@ -947,12 +948,10 @@ wxFontEncoding wxFont::GetEncoding() const
     return M_FONTDATA->GetEncoding();
 }
 
     return M_FONTDATA->GetEncoding();
 }
 
-wxNativeFontInfo *wxFont::GetNativeFontInfo() const
+const wxNativeFontInfo *wxFont::GetNativeFontInfo() const
 {
 {
-    if ( M_FONTDATA->HasNativeFontInfo() )
-        return new wxNativeFontInfo(M_FONTDATA->GetNativeFontInfo());
-
-    return 0;
+    return M_FONTDATA->HasNativeFontInfo() ? &(M_FONTDATA->GetNativeFontInfo())
+                                           : NULL;
 }
 
 bool wxFont::IsFixedWidth() const
 }
 
 bool wxFont::IsFixedWidth() const