[MPlayer-cvslog] r19907 - trunk/libass/ass_fontconfig.c
eugeni
subversion at mplayerhq.hu
Tue Sep 19 15:06:44 CEST 2006
Author: eugeni
Date: Tue Sep 19 15:06:44 2006
New Revision: 19907
Modified:
trunk/libass/ass_fontconfig.c
Log:
Don't call FcDirScan/FcDirSave with FontConfig >= 2.4.
Font cache is updated automatically in FcConfigAppFontAddDir.
Modified: trunk/libass/ass_fontconfig.c
==============================================================================
--- trunk/libass/ass_fontconfig.c (original)
+++ trunk/libass/ass_fontconfig.c Tue Sep 19 15:06:44 2006
@@ -154,9 +154,11 @@
if (FcDirCacheValid((const FcChar8 *)dir) == FcFalse)
{
+ mp_msg(MSGT_GLOBAL, MSGL_INFO, "[ass] Updating font cache\n");
+ // FontConfig >= 2.4.0 updates cache automatically in FcConfigAppFontAddDir()
+ if (FcGetVersion() < 20400) {
FcFontSet* fcs;
FcStrSet* fss;
- mp_msg(MSGT_GLOBAL, MSGL_INFO, "[ass] Updating font cache\n");
fcs = FcFontSetCreate();
fss = FcStrSetCreate();
rc = FcStrSetAdd(fss, (const FcChar8*)dir);
@@ -178,6 +180,7 @@
}
ErrorFontCache:
;
+ }
}
rc = FcConfigAppFontAddDir(priv->config, (const FcChar8*)dir);
More information about the MPlayer-cvslog
mailing list