From f23bce965ce375a647898988ba04864aa30add20 Mon Sep 17 00:00:00 2001 From: sgimenez Date: Sat, 2 Dec 2006 13:33:58 +0000 Subject: [PATCH] fix for bug #1600900, freetype internals must not be used. but, the replacement "FT_Get_X11_Font_Format" is still a hack, headers says: "It should only be used by the FreeType 2 font backend of the XFree86 font server." --- src/extension/internal/ps.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/extension/internal/ps.cpp b/src/extension/internal/ps.cpp index 1301e888a..6392c33d8 100644 --- a/src/extension/internal/ps.cpp +++ b/src/extension/internal/ps.cpp @@ -64,7 +64,7 @@ #include #include FT_FREETYPE_H -#include +#include #include #include #include @@ -928,7 +928,7 @@ PrintPS::embed_t1 (SVGOStringStream &os, font_instance* font) { //check font type FT_Face font_face = pango_ft2_font_get_face(font->pFont); - const FT_String* font_type = FT_MODULE_CLASS(font_face->driver)->module_name; + const FT_String* font_type = FT_Get_X11_Font_Format(font_face); g_return_val_if_fail (_fontTypesMap[font_type] == FONT_TYPE1, false); //get font filename, stream to font file and size FT_Stream font_stream = font_face->stream; @@ -1150,7 +1150,7 @@ bool PrintPS::embed_font(SVGOStringStream &os, font_instance* font) //Hinted at by a comment in libgnomeprint/fcpattern_to_gp_font_entry() //Determining the font type in the "Pango way" FT_Face font_face = pango_ft2_font_get_face(font->pFont); - const FT_String* font_type = FT_MODULE_CLASS(font_face->driver)->module_name; + const FT_String* font_type = FT_Get_X11_Font_Format(font_face); /** * Possible values of "font_type" variable, not supported (font types): -- 2.30.2