]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk/gnome/gprint.cpp
fix unused variable warning in release build
[wxWidgets.git] / src / gtk / gnome / gprint.cpp
index 2e389c56e6cc464cb4a5499c375f06b19460ebeb..737bfc374b04aed26b9318df0e8e0ef01227161b 100644 (file)
@@ -1920,13 +1920,13 @@ void wxGnomePrinterDCImpl::DoGetTextExtent(const wxString& string, wxCoord *widt
     const wxCharBuffer dataUTF8 = string.utf8_str();
 #endif
 
-    gint oldSize;
+    gint oldSize = 0;
     if ( theFont )
     {
         // scale the font and apply it
         PangoFontDescription *desc = theFont->GetNativeFontInfo()->description;
-        float size = pango_font_description_get_size(desc);
-        size = size * GetFontPointSizeAdjustment(72.0);
+        oldSize = pango_font_description_get_size(desc);
+        float size = oldSize * GetFontPointSizeAdjustment(72.0);
         pango_font_description_set_size(desc, (gint)size);
 
         pango_layout_set_font_description(m_layout, desc);