]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk1/font.cpp
Patch 559673 and 561053
[wxWidgets.git] / src / gtk1 / font.cpp
index 1637fb8a9a346b672b789c5db164d69287eb1451..79921f481a8534a166b06a33e0fd9147d350933f 100644 (file)
@@ -30,9 +30,8 @@
 
 #include <strings.h>
 
-#include <gdk/gdk.h>
+#include "wx/gtk/private.h"
 #include <gdk/gdkprivate.h>
-#include <gtk/gtk.h>
 
 // ----------------------------------------------------------------------------
 // constants
@@ -175,6 +174,7 @@ void wxFontRefData::Init(int pointSize,
 }
 
 wxFontRefData::wxFontRefData( const wxFontRefData& data )
+    : wxObjectRefData()
 {
     m_pointSize = data.m_pointSize;
     m_family = data.m_family;
@@ -656,13 +656,13 @@ extern GdkFont *GtkGetDefaultGuiFont()
         GtkStyle *def = gtk_rc_get_style( widget );
         if (def)
         {
-            g_systemDefaultGuiFont = gdk_font_ref( def->font );
+            g_systemDefaultGuiFont = gdk_font_ref( GET_STYLE_FONT(def) );
         }
         else
         {
             def = gtk_widget_get_default_style();
             if (def)
-                g_systemDefaultGuiFont = gdk_font_ref( def->font );
+                g_systemDefaultGuiFont = gdk_font_ref( GET_STYLE_FONT(def) );
         }
         gtk_widget_destroy( widget );
     }