Revert ABI changes from version 2.3

Accidental ABI changes and additions were discovered by looking at the
differences in fontconfig.h. All of those have been reverted.
This commit is contained in:
Keith Packard 2006-08-31 14:38:18 -07:00
parent 0a87ce715e
commit f57783d2e9
5 changed files with 28 additions and 23 deletions

View File

@ -227,7 +227,7 @@ scanDirs (FcStrList *list, FcConfig *config, char *program, FcBool force, FcBool
FcDirCacheUnlink (dir, config);
if (!force)
was_valid = FcDirCacheValid (dir, config);
was_valid = FcDirCacheValid (dir);
if (!FcDirScanConfig (set, subdirs, FcConfigGetBlanks (config), dir, force, config))
{
@ -249,7 +249,7 @@ scanDirs (FcStrList *list, FcConfig *config, char *program, FcBool force, FcBool
printf ("caching, %d fonts, %d dirs\n",
set->nfont, nsubdirs (subdirs));
if (!FcDirCacheValid (dir, config))
if (!FcDirCacheValid (dir))
{
fprintf (stderr, "%s: failed to write cache\n", dir);
(void) FcDirCacheUnlink (dir, config);

View File

@ -150,7 +150,7 @@ main (int argc, char **argv)
FcChar8 *font;
FcChar8 *file;
font = FcNameUnparseEscaped (fs->fonts[j], FcFalse);
font = FcNameUnparse (fs->fonts[j]);
if (FcPatternGetString (fs->fonts[j], FC_FILE, 0, &file) == FcResultMatch)
printf ("%s: ", file);
printf ("%s\n", font);

View File

@ -211,15 +211,15 @@ typedef struct _FcLangSet FcLangSet;
typedef struct _FcValue {
FcType type;
union {
const FcChar8 *s;
const FcChar8 *s;
int i;
FcBool b;
double d;
const FcMatrix *m;
const FcCharSet *c;
const FcMatrix *m;
const FcCharSet *c;
void *f;
const FcPattern *p;
const FcLangSet *l;
const FcLangSet *l;
} u;
} FcValue;
@ -273,13 +273,7 @@ typedef struct _FcStrSet FcStrSet;
_FCFUNCPROTOBEGIN
FcBool
FcDirCacheValid (const FcChar8 *cache_file, FcConfig *config);
FcBool
FcDirCacheHasCurrentArch (const FcChar8 *dir, FcConfig *config);
FcBool
FcDirCacheUnlink (const FcChar8 *dir, FcConfig *config);
FcDirCacheValid (const FcChar8 *cache_file);
/* fcblanks.c */
FcBlanks *
@ -325,10 +319,6 @@ FcConfigBuildFonts (FcConfig *config);
FcStrList *
FcConfigGetFontDirs (FcConfig *config);
const FcChar8 *
FcConfigNormalizeFontDir (FcConfig *config,
const FcChar8 *d);
FcStrList *
FcConfigGetConfigDirs (FcConfig *config);
@ -665,9 +655,6 @@ FcNameParse (const FcChar8 *name);
FcChar8 *
FcNameUnparse (FcPattern *pat);
FcChar8 *
FcNameUnparseEscaped (FcPattern *pat, FcBool escape);
/* fcpat.c */
FcPattern *
FcPatternCreate (void);

View File

@ -379,12 +379,24 @@ FcDirCacheValidate (int fd, off_t size, void *closure)
return ret;
}
FcBool
FcDirCacheValid (const FcChar8 *dir, FcConfig *config)
static FcBool
FcDirCacheValidConfig (const FcChar8 *dir, FcConfig *config)
{
return FcDirCacheProcess (config, dir, FcDirCacheValidate, NULL, NULL);
}
FcBool
FcDirCacheValid (const FcChar8 *dir)
{
FcConfig *config;
config = FcConfigGetCurrent ();
if (!config)
return FcFalse;
return FcDirCacheValidConfig (dir, config);
}
void
FcDirCacheUnmap (FcCache *cache)
{

View File

@ -512,6 +512,9 @@ FcDirCacheMap (const FcChar8 *dir, FcConfig *config, FcChar8 **cache_file);
FcBool
FcDirCacheLoad (int fd, off_t size, void *closure);
FcBool
FcDirCacheUnlink (const FcChar8 *dir, FcConfig *config);
/* fccfg.c */
FcBool
@ -803,6 +806,9 @@ FcNameParseLangSet (const FcChar8 *string);
FcBool
FcNameUnparseLangSet (FcStrBuf *buf, const FcLangSet *ls);
FcChar8 *
FcNameUnparseEscaped (FcPattern *pat, FcBool escape);
/* fclist.c */
FcBool