Improve the performance issue on rescanning directories
[platform/upstream/fontconfig.git] / src / fcint.h
index ec0c674..cdf2dab 100644 (file)
@@ -174,10 +174,11 @@ typedef struct _FcValueList {
                        
 typedef int FcObject;
 
-/* The 1000 is to leave some room for future added internal objects, such
+/* The 1024 is to leave some room for future added internal objects, such
  * that caches from newer fontconfig can still be used with older fontconfig
  * without getting confused. */
-#define FC_EXT_OBJ_INDEX       1000
+#define FC_EXT_OBJ_INDEX       1024
+#define FC_OBJ_ID(_n_) ((_n_) & (~FC_EXT_OBJ_INDEX))
 
 typedef struct _FcPatternElt *FcPatternEltPtr;
 
@@ -566,6 +567,9 @@ FcDirCacheScan (const FcChar8 *dir, FcConfig *config);
 FcPrivate FcCache *
 FcDirCacheBuild (FcFontSet *set, const FcChar8 *dir, struct stat *dir_stat, FcStrSet *dirs);
 
+FcPrivate FcCache *
+FcDirCacheRebuild (FcCache *cache, struct stat *dir_stat, FcStrSet *dirs);
+
 FcPrivate FcBool
 FcDirCacheWrite (FcCache *cache, FcConfig *config);
 
@@ -837,6 +841,9 @@ FcFontSetSerializeAlloc (FcSerialize *serialize, const FcFontSet *s);
 FcPrivate FcFontSet *
 FcFontSetSerialize (FcSerialize *serialize, const FcFontSet * s);
 
+FcPrivate FcFontSet *
+FcFontSetDeserialize (const FcFontSet *set);
+
 /* fchash.c */
 FcPrivate FcChar8 *
 FcHashGetSHA256Digest (const FcChar8 *input_strings,