X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/3398cf2cf6cc2eaae7de6d8b3666229092439078..065ab451bf9bcf7986049ff82b8b456ecc559aa4:/src/unix/fontutil.cpp diff --git a/src/unix/fontutil.cpp b/src/unix/fontutil.cpp index e422117996..79f36b31dd 100644 --- a/src/unix/fontutil.cpp +++ b/src/unix/fontutil.cpp @@ -57,6 +57,20 @@ void wxNativeFontInfo::Init() description = NULL; } +wxNativeFontInfo::wxNativeFontInfo(const wxNativeFontInfo& info) +{ + if (info.description) + description = pango_font_description_copy(info.description); + else + description = NULL; +} + +wxNativeFontInfo::~wxNativeFontInfo() +{ + if (description) + pango_font_description_free(description); +} + int wxNativeFontInfo::GetPointSize() const { return pango_font_description_get_size( description ) / PANGO_SCALE; @@ -563,13 +577,13 @@ bool wxNativeFontInfo::GetUnderlined() const wxString wxNativeFontInfo::GetFaceName() const { - // wxWindows facename probably more accurately corresponds to X family + // wxWidgets facename probably more accurately corresponds to X family return GetXFontComponent(wxXLFD_FAMILY); } wxFontFamily wxNativeFontInfo::GetFamily() const { - // and wxWindows family -- to X foundry, but we have to translate it to + // and wxWidgets family -- to X foundry, but we have to translate it to // wxFontFamily somehow... wxFAIL_MSG(_T("not implemented")); // GetXFontComponent(wxXLFD_FOUNDRY); @@ -715,6 +729,7 @@ bool wxGetNativeFontEncoding(wxFontEncoding encoding, break; case wxFONTENCODING_KOI8: + case wxFONTENCODING_KOI8_U: info->xregistry = wxT("koi8"); // we don't make distinction between koi8-r, koi8-u and koi8-ru (so far)