From 1175aa4e13bc3cf9ae9c5cf9458bc0cfd23796ce Mon Sep 17 00:00:00 2001 From: Robert Roebling Date: Sat, 5 Feb 2005 12:49:08 +0000 Subject: [PATCH] Blind patch for SetFont() in Unicode mode for wxX11. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@31763 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- src/x11/dcclient.cpp | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/x11/dcclient.cpp b/src/x11/dcclient.cpp index 8cbaf34a0d..37b47a4dbf 100644 --- a/src/x11/dcclient.cpp +++ b/src/x11/dcclient.cpp @@ -1771,6 +1771,16 @@ void wxWindowDC::SetFont( const wxFont &font ) wxCHECK_RET( Ok(), wxT("invalid dc") ); m_font = font; + +#if wxUSE_UNICODE + if (m_font.Ok()) + { + if (m_fontdesc) + pango_font_description_free( m_fontdesc ); + + m_fontdesc = pango_font_description_copy( m_font.GetNativeFontInfo()->description ); + } +#endif } void wxWindowDC::SetPen( const wxPen &pen )