Add autoconf checks for FT_Has_PS_Glyph_Names

This commit is contained in:
Keith Packard 2003-06-26 08:19:11 +00:00
parent ee1debfdd9
commit 656c69d6a8
2 changed files with 8 additions and 1 deletions

View File

@ -117,11 +117,12 @@ AC_SUBST(FREETYPE_CFLAGS)
# FT_Get_Next_Char # FT_Get_Next_Char
# FT_Get_BDF_Property # FT_Get_BDF_Property
# FT_Get_PS_Font_Info # FT_Get_PS_Font_Info
# FT_Has_PS_Glyph_Names
# #
fontconfig_save_libs=$LIBS fontconfig_save_libs=$LIBS
LIBS="$LIBS $FREETYPE_LIBS" LIBS="$LIBS $FREETYPE_LIBS"
AC_CHECK_FUNCS(FT_Get_Next_Char FT_Get_BDF_Property FT_Get_PS_Font_Info) AC_CHECK_FUNCS(FT_Get_Next_Char FT_Get_BDF_Property FT_Get_PS_Font_Info FT_Has_PS_Glyph_Names)
LIBS=$fontconfig_save_libs LIBS=$fontconfig_save_libs
# #

View File

@ -1599,6 +1599,7 @@ FcHashGlyphName (const FcChar8 *name)
return h; return h;
} }
#if HAVE_FT_HAS_PS_GLYPH_NAMES
/* /*
* Use Type1 glyph names for fonts which have reliable names * Use Type1 glyph names for fonts which have reliable names
* and which export an Adobe Custom mapping * and which export an Adobe Custom mapping
@ -1684,6 +1685,7 @@ FcFreeTypeGlyphNameIndex (FT_Face face, FcChar8 *name)
} }
return 0; return 0;
} }
#endif
/* /*
* Map a UCS4 glyph to a glyph index. Use all available encoding * Map a UCS4 glyph to a glyph index. Use all available encoding
@ -1731,6 +1733,7 @@ FcFreeTypeCharIndex (FT_Face face, FcChar32 ucs4)
if (glyphindex) if (glyphindex)
return glyphindex; return glyphindex;
} }
#if HAVE_FT_HAS_PS_GLYPH_NAMES
/* /*
* Check postscript name table if present * Check postscript name table if present
*/ */
@ -1744,6 +1747,7 @@ FcFreeTypeCharIndex (FT_Face face, FcChar32 ucs4)
return glyphindex; return glyphindex;
} }
} }
#endif
return 0; return 0;
} }
@ -1933,6 +1937,7 @@ FcFreeTypeCharSetAndSpacing (FT_Face face, FcBlanks *blanks, int *spacing)
#endif #endif
} }
} }
#if HAVE_FT_HAS_PS_GLYPH_NAMES
/* /*
* Add mapping from PS glyph names if available * Add mapping from PS glyph names if available
*/ */
@ -1967,6 +1972,7 @@ FcFreeTypeCharSetAndSpacing (FT_Face face, FcBlanks *blanks, int *spacing)
} }
} }
} }
#endif
#ifdef CHECK #ifdef CHECK
printf ("%d glyphs %d encoded\n", (int) face->num_glyphs, FcCharSetCount (fcs)); printf ("%d glyphs %d encoded\n", (int) face->num_glyphs, FcCharSetCount (fcs));
for (ucs4 = 0; ucs4 <= font_max; ucs4++) for (ucs4 = 0; ucs4 <= font_max; ucs4++)