Commit ef815771 authored by Albert Astals Cid's avatar Albert Astals Cid

Fix my fix of #96085 as freetype treats all CID fonts the same way only from 2.1.8 and up

Kurt can you check that fixes the problem with characters not beign correctly displayed on firefox nytimes pdf?
CCMAIL: 96085@bugs.kde.org
CCMAIL: 95985@bugs.kde.org

svn path=/trunk/kdegraphics/kpdf/; revision=378732
parent 2b8427a5
......@@ -19,6 +19,12 @@ if test -n "$FREETYPE_CONFIG"; then
LIBFREETYPE_RPATH=`echo $LIBFREETYPE_RPATH | sed -e "s/-L/-R/g"`
LIBFREETYPE_CFLAGS="`$FREETYPE_CONFIG --cflags`"
AC_DEFINE_UNQUOTED(HAVE_FREETYPE, 1, [Defines if your system has the freetype library])
if test -n "$vers" && test "$vers" -le 9005003; then
AC_DEFINE_UNQUOTED(HAVE_FREETYPE_217_OR_OLDER, 1, [Defines if your system has the freetype library 2.1.7 or older])
else
AC_DEFINE_UNQUOTED(HAVE_FREETYPE_217_OR_OLDER, 0, [Defines if your system has the freetype library 2.1.7 or older])
fi
else
AC_MSG_WARN([You need at least libfreetype 2.0.5])
fi
......
......@@ -80,14 +80,19 @@ SplashFontFile *SplashFTFontEngine::loadCIDFont(SplashFontFileID *idA,
SplashFontFile *ret;
// check for a CFF font
/*if ((ff = FoFiType1C::load(fileName))) {
#if HAVE_FREETYPE_217_OR_OLDER
if ((ff = FoFiType1C::load(fileName))) {
cidToGIDMap = ff->getCIDToGIDMap(&nCIDs);
delete ff;
} else {*/
// No need to check for CFF Font, freetype treats all CID fonts the same way
} else {
cidToGIDMap = NULL;
nCIDs = 0;
//}
}
#else
// Freetype 2.1.8 and up treats all CID fonts the same way
cidToGIDMap = NULL;
nCIDs = 0;
#endif
ret = SplashFTFontFile::loadCIDFont(this, idA, fileName, deleteFile,
cidToGIDMap, nCIDs);
if (!ret) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment