X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/696f36b70dc953773edd68e26a82f8258432fdf5..9c34dd9deafaa428534b498b90799687a7dcddaa:/src/gtk/dcclient.cpp diff --git a/src/gtk/dcclient.cpp b/src/gtk/dcclient.cpp index 13c896c00e..1af1943549 100644 --- a/src/gtk/dcclient.cpp +++ b/src/gtk/dcclient.cpp @@ -20,6 +20,7 @@ #include "wx/image.h" #include "wx/module.h" #include "wx/log.h" +#include "wx/fontutil.h" #include "wx/gtk/win_gtk.h" @@ -203,7 +204,7 @@ static void wxInitGCPool() static void wxCleanUpGCPool() { - for (int i = 0; i < GC_POOL_SIZE; i++) + for (int i = 0; i < wxGCPoolSize; i++) { if (wxGCPool[i].m_gc) gdk_gc_unref( wxGCPool[i].m_gc ); @@ -330,6 +331,7 @@ wxWindowDC::wxWindowDC( wxWindow *window ) #ifdef __WXGTK20__ m_context = gtk_widget_get_pango_context( widget ); + m_fontdesc = widget->style->font_desc; #endif @@ -1555,7 +1557,7 @@ void wxWindowDC::DoDrawRotatedText( const wxString &text, wxCoord x, wxCoord y, // don't use DrawPoint() because it uses the current pen // colour, and we don't need it here gdk_draw_point( m_window, m_textGC, - XLOG2DEV(x + dstX), YLOG2DEV(y + dstY) ); + XLOG2DEV(x) + dstX, YLOG2DEV(y) + dstY ); } } } @@ -1656,7 +1658,7 @@ void wxWindowDC::SetFont( const wxFont &font ) m_font = font; #ifdef __WXGTK20__ - // fix fontdesc? + m_fontdesc = m_font.GetNativeFontInfo()->description; #endif }