2 * fontconfig/src/fcint.h
4 * Copyright © 2000 Keith Packard
6 * Permission to use, copy, modify, distribute, and sell this software and its
7 * documentation for any purpose is hereby granted without fee, provided that
8 * the above copyright notice appear in all copies and that both that
9 * copyright notice and this permission notice appear in supporting
10 * documentation, and that the name of the author(s) not be used in
11 * advertising or publicity pertaining to distribution of the software without
12 * specific, written prior permission. The authors make no
13 * representations about the suitability of this software for any purpose. It
14 * is provided "as is" without express or implied warranty.
16 * THE AUTHOR(S) DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE,
17 * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO
18 * EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY SPECIAL, INDIRECT OR
19 * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE,
20 * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER
21 * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
22 * PERFORMANCE OF THIS SOFTWARE.
41 #include <sys/types.h>
44 #include <fontconfig/fontconfig.h>
45 #include <fontconfig/fcprivate.h>
46 #include "fcdeprecate.h"
50 #ifndef FC_CONFIG_PATH
51 #define FC_CONFIG_PATH "fonts.conf"
56 # define _WIN32_WINNT 0x0500
58 # define WIN32_LEAN_AND_MEAN
61 typedef UINT (WINAPI *pfnGetSystemWindowsDirectory)(LPSTR, UINT);
62 typedef HRESULT (WINAPI *pfnSHGetFolderPathA)(HWND, int, HANDLE, DWORD, LPSTR);
63 extern pfnGetSystemWindowsDirectory pGetSystemWindowsDirectory;
64 extern pfnSHGetFolderPathA pSHGetFolderPathA;
65 # define FC_SEARCH_PATH_SEPARATOR ';'
66 # define FC_DIR_SEPARATOR '\\'
67 # define FC_DIR_SEPARATOR_S "\\"
69 # define FC_SEARCH_PATH_SEPARATOR ':'
70 # define FC_DIR_SEPARATOR '/'
71 # define FC_DIR_SEPARATOR_S "/"
75 #define FC_UNUSED __attribute__((unused))
80 #define FC_DBG_MATCH 1
81 #define FC_DBG_MATCHV 2
83 #define FC_DBG_FONTSET 8
84 #define FC_DBG_CACHE 16
85 #define FC_DBG_CACHEV 32
86 #define FC_DBG_PARSE 64
87 #define FC_DBG_SCAN 128
88 #define FC_DBG_SCANV 256
89 #define FC_DBG_CONFIG 1024
90 #define FC_DBG_LANGSET 2048
92 #define _FC_ASSERT_STATIC1(_line, _cond) typedef int _static_assert_on_line_##_line##_failed[(_cond)?1:-1]
93 #define _FC_ASSERT_STATIC0(_line, _cond) _FC_ASSERT_STATIC1 (_line, (_cond))
94 #define FC_ASSERT_STATIC(_cond) _FC_ASSERT_STATIC0 (__LINE__, (_cond))
96 #define FC_MIN(a,b) ((a) < (b) ? (a) : (b))
97 #define FC_MAX(a,b) ((a) > (b) ? (a) : (b))
98 #define FC_ABS(a) ((a) < 0 ? -(a) : (a))
100 /* slim_internal.h */
101 #if (__GNUC__ > 3 || (__GNUC__ == 3 && __GNUC_MINOR__ >= 3)) && defined(__ELF__) && !defined(__sun)
102 #define FcPrivate __attribute__((__visibility__("hidden")))
103 #define HAVE_GNUC_ATTRIBUTE 1
105 #elif defined(__SUNPRO_C) && (__SUNPRO_C >= 0x550)
106 #define FcPrivate __hidden
107 #else /* not gcc >= 3.3 and not Sun Studio >= 8 */
111 typedef enum _FcValueBinding {
112 FcValueBindingWeak, FcValueBindingStrong, FcValueBindingSame
116 * Serialized data structures use only offsets instead of pointers
117 * A low bit of 1 indicates an offset.
120 /* Is the provided pointer actually an offset? */
121 #define FcIsEncodedOffset(p) ((((intptr_t) (p)) & 1) != 0)
123 /* Encode offset in a pointer of type t */
124 #define FcOffsetEncode(o,t) ((t *) ((o) | 1))
126 /* Decode a pointer into an offset */
127 #define FcOffsetDecode(p) (((intptr_t) (p)) & ~1)
129 /* Compute pointer offset */
130 #define FcPtrToOffset(b,p) ((intptr_t) (p) - (intptr_t) (b))
132 /* Given base address, offset and type, return a pointer */
133 #define FcOffsetToPtr(b,o,t) ((t *) ((intptr_t) (b) + (o)))
135 /* Given base address, encoded offset and type, return a pointer */
136 #define FcEncodedOffsetToPtr(b,p,t) FcOffsetToPtr(b,FcOffsetDecode(p),t)
138 /* Given base address, pointer and type, return an encoded offset */
139 #define FcPtrToEncodedOffset(b,p,t) FcOffsetEncode(FcPtrToOffset(b,p),t)
141 /* Given a structure, offset member and type, return pointer */
142 #define FcOffsetMember(s,m,t) FcOffsetToPtr(s,(s)->m,t)
144 /* Given a structure, encoded offset member and type, return pointer to member */
145 #define FcEncodedOffsetMember(s,m,t) FcOffsetToPtr(s,FcOffsetDecode((s)->m), t)
147 /* Given a structure, member and type, convert the member to a pointer */
148 #define FcPointerMember(s,m,t) (FcIsEncodedOffset((s)->m) ? \
149 FcEncodedOffsetMember (s,m,t) : \
153 * Serialized values may hold strings, charsets and langsets as pointers,
154 * unfortunately FcValue is an exposed type so we can't just always use
157 #define FcValueString(v) FcPointerMember(v,u.s,FcChar8)
158 #define FcValueCharSet(v) FcPointerMember(v,u.c,const FcCharSet)
159 #define FcValueLangSet(v) FcPointerMember(v,u.l,const FcLangSet)
161 typedef struct _FcValueList *FcValueListPtr;
163 typedef struct _FcValueList {
164 struct _FcValueList *next;
166 FcValueBinding binding;
169 #define FcValueListNext(vl) FcPointerMember(vl,next,FcValueList)
171 typedef int FcObject;
173 typedef struct _FcPatternElt *FcPatternEltPtr;
176 * Pattern elts are stuck in a structure connected to the pattern,
177 * so they get moved around when the pattern is resized. Hence, the
178 * values field must be a pointer/offset instead of just an offset
180 typedef struct _FcPatternElt {
185 #define FcPatternEltValues(pe) FcPointerMember(pe,values,FcValueList)
190 intptr_t elts_offset;
194 #define FcPatternElts(p) FcOffsetMember(p,elts_offset,FcPatternElt)
196 #define FcFontSetFonts(fs) FcPointerMember(fs,fonts,FcPattern *)
198 #define FcFontSetFont(fs,i) (FcIsEncodedOffset((fs)->fonts) ? \
199 FcEncodedOffsetToPtr(fs, \
200 FcFontSetFonts(fs)[i], \
205 FcOpInteger, FcOpDouble, FcOpString, FcOpMatrix, FcOpRange, FcOpBool, FcOpCharSet, FcOpLangSet,
207 FcOpField, FcOpConst,
208 FcOpAssign, FcOpAssignReplace,
209 FcOpPrependFirst, FcOpPrepend, FcOpAppend, FcOpAppendLast,
211 FcOpOr, FcOpAnd, FcOpEqual, FcOpNotEqual,
212 FcOpContains, FcOpListing, FcOpNotContains,
213 FcOpLess, FcOpLessEqual, FcOpMore, FcOpMoreEqual,
214 FcOpPlus, FcOpMinus, FcOpTimes, FcOpDivide,
215 FcOpNot, FcOpComma, FcOpFloor, FcOpCeil, FcOpRound, FcOpTrunc,
219 typedef enum _FcOpFlags {
220 FcOpFlagIgnoreBlanks = 1 << 0
223 #define FC_OP_GET_OP(_x_) ((_x_) & 0xffff)
224 #define FC_OP_GET_FLAGS(_x_) (((_x_) & 0xffff0000) >> 16)
225 #define FC_OP(_x_,_f_) (FC_OP_GET_OP (_x_) | ((_f_) << 16))
227 typedef struct _FcExprMatrix {
228 struct _FcExpr *xx, *xy, *yx, *yy;
231 typedef struct _FcExprName {
237 typedef struct _FcExpr {
249 const FcChar8 *constant;
251 struct _FcExpr *left, *right;
256 typedef struct _FcExprPage FcExprPage;
259 FcExprPage *next_page;
261 FcExpr exprs[(1024 - 2/* two pointers */ - 2/* malloc overhead */) * sizeof (void *) / sizeof (FcExpr)];
262 FcExpr end[FLEXIBLE_ARRAY_MEMBER];
265 typedef enum _FcQual {
266 FcQualAny, FcQualAll, FcQualFirst, FcQualNotFirst
269 #define FcMatchDefault ((FcMatchKind) -1)
271 typedef struct _FcTest {
272 struct _FcTest *next;
280 typedef struct _FcEdit {
281 struct _FcEdit *next;
285 FcValueBinding binding;
288 typedef struct _FcSubst {
289 struct _FcSubst *next;
294 typedef struct _FcCharLeaf {
295 FcChar32 map[256/32];
299 int ref; /* reference count */
300 int num; /* size of leaves and numbers arrays */
301 intptr_t leaves_offset;
302 intptr_t numbers_offset;
305 #define FcCharSetLeaves(c) FcOffsetMember(c,leaves_offset,intptr_t)
306 #define FcCharSetLeaf(c,i) (FcOffsetToPtr(FcCharSetLeaves(c), \
307 FcCharSetLeaves(c)[i], \
309 #define FcCharSetNumbers(c) FcOffsetMember(c,numbers_offset,FcChar16)
312 int ref; /* reference count */
323 typedef struct _FcStrBuf {
329 FcChar8 buf_static[16 * sizeof (void *)];
333 unsigned int magic; /* FC_CACHE_MAGIC_MMAP or FC_CACHE_ALLOC */
334 int version; /* FC_CACHE_CONTENT_VERSION */
335 intptr_t size; /* size of file */
336 intptr_t dir; /* offset to dir name */
337 intptr_t dirs; /* offset to subdirs */
338 int dirs_count; /* number of subdir strings */
339 intptr_t set; /* offset to font set */
340 int checksum; /* checksum of directory state */
345 #define FcCacheDir(c) FcOffsetMember(c,dir,FcChar8)
346 #define FcCacheDirs(c) FcOffsetMember(c,dirs,intptr_t)
347 #define FcCacheSet(c) FcOffsetMember(c,set,FcFontSet)
348 #define FcCacheSubdir(c,i) FcOffsetToPtr (FcCacheDirs(c),\
353 * Used while constructing a directory cache object
356 #define FC_SERIALIZE_HASH_SIZE 8191
358 typedef union _FcAlign {
366 typedef struct _FcSerializeBucket {
367 struct _FcSerializeBucket *next;
372 typedef struct _FcCharSetFreezer FcCharSetFreezer;
374 typedef struct _FcSerialize {
376 FcCharSetFreezer *cs_freezer;
378 FcSerializeBucket *buckets[FC_SERIALIZE_HASH_SIZE];
382 * To map adobe glyph names to unicode values, a precomputed hash
386 typedef struct _FcGlyphName {
387 FcChar32 ucs; /* unicode value */
388 FcChar8 name[1]; /* name extends beyond struct */
392 * To perform case-insensitive string comparisons, a table
393 * is used which holds three different kinds of folding data.
395 * The first is a range of upper case values mapping to a range
396 * of their lower case equivalents. Within each range, the offset
397 * between upper and lower case is constant.
399 * The second is a range of upper case values which are interleaved
400 * with their lower case equivalents.
402 * The third is a set of raw unicode values mapping to a list
403 * of unicode values for comparison purposes. This allows conversion
404 * of ß to "ss" so that SS, ss and ß all match. A separate array
405 * holds the list of unicode values for each entry.
407 * These are packed into a single table. Using a binary search,
408 * the appropriate entry can be located.
411 #define FC_CASE_FOLD_RANGE 0
412 #define FC_CASE_FOLD_EVEN_ODD 1
413 #define FC_CASE_FOLD_FULL 2
415 typedef struct _FcCaseFold {
419 short offset; /* lower - upper for RANGE, table id for FULL */
422 #define FC_MAX_FILE_LEN 4096
424 #define FC_CACHE_MAGIC_MMAP 0xFC02FC04
425 #define FC_CACHE_MAGIC_ALLOC 0xFC02FC05
426 #define FC_CACHE_CONTENT_VERSION 3
429 FcChar8 *file; /* original file name */
430 FcChar8 *new; /* temp file name -- write data here */
431 FcChar8 *lck; /* lockfile name (used for locking) */
432 FcChar8 *tmp; /* tmpfile name (used for locking) */
443 * File names loaded from the configuration -- saved here as the
444 * cache file must be consulted before the directories are scanned,
445 * and those directives may occur in any order
447 FcStrSet *configDirs; /* directories to scan for fonts */
449 * Set of allowed blank chars -- used to
450 * trim fonts of bogus glyphs
454 * List of directories containing fonts,
455 * built by recursively scanning the set
456 * of configured directories
460 * List of directories containing cache files.
464 * Names of all of the configuration files used
465 * to create this configuration
467 FcStrSet *configFiles; /* config files loaded */
469 * Substitution instructions for patterns and fonts;
470 * maxObjects is used to allocate appropriate intermediate storage
471 * while performing a whole set of substitutions
473 FcSubst *substPattern; /* substitutions for patterns */
474 FcSubst *substFont; /* substitutions for fonts */
475 FcSubst *substScan; /* substitutions for scanned fonts */
476 int maxObjects; /* maximum number of tests in all substs */
478 * List of patterns used to control font file selection
480 FcStrSet *acceptGlobs;
481 FcStrSet *rejectGlobs;
482 FcFontSet *acceptPatterns;
483 FcFontSet *rejectPatterns;
485 * The set of fonts loaded from the listed directories; the
486 * order within the set does not determine the font selection,
487 * except in the case of identical matches in which case earlier fonts
488 * match preferrentially
490 FcFontSet *fonts[FcSetApplication + 1];
492 * Fontconfig can periodically rescan the system configuration
493 * and font directories. This rescanning occurs when font
494 * listing requests are made, but no more often than rescanInterval
497 time_t rescanTime; /* last time information was scanned */
498 int rescanInterval; /* interval between scans */
500 int ref; /* reference count */
502 FcExprPage *expr_pool; /* pool of FcExpr's */
505 extern FcPrivate FcConfig *_fcConfig;
507 typedef struct _FcFileTime {
512 typedef struct _FcCharMap FcCharMap;
514 typedef struct _FcRange FcRange;
521 typedef struct _FcStatFS FcStatFS;
525 FcBool is_mtime_broken;
533 FcDirCacheScan (const FcChar8 *dir, FcConfig *config);
536 FcDirCacheBuild (FcFontSet *set, const FcChar8 *dir, struct stat *dir_stat, FcStrSet *dirs);
539 FcDirCacheWrite (FcCache *cache, FcConfig *config);
542 FcDirCacheCreateTagFile (const FcChar8 *cache_dir);
545 FcCacheObjectReference (void *object);
548 FcCacheObjectDereference (void *object);
554 FcDirCacheReference (FcCache *cache, int nref);
559 FcConfigXdgCacheHome (void);
562 FcConfigXdgConfigHome (void);
565 FcConfigXdgDataHome (void);
568 FcConfigAllocExpr (FcConfig *config);
571 FcConfigAddConfigDir (FcConfig *config,
575 FcConfigAddFontDir (FcConfig *config,
579 FcConfigAddDir (FcConfig *config,
583 FcConfigAddCacheDir (FcConfig *config,
587 FcConfigAddConfigFile (FcConfig *config,
591 FcConfigAddBlank (FcConfig *config,
595 FcConfigAddEdit (FcConfig *config,
601 FcConfigSetFonts (FcConfig *config,
606 FcConfigCompareValue (const FcValue *m,
611 FcConfigGlobAdd (FcConfig *config,
616 FcConfigAcceptFilename (FcConfig *config,
617 const FcChar8 *filename);
620 FcConfigPatternsAdd (FcConfig *config,
625 FcConfigAcceptFont (FcConfig *config,
626 const FcPattern *font);
629 FcConfigModifiedTime (FcConfig *config);
632 FcConfigAddCache (FcConfig *config, FcCache *cache,
633 FcSetName set, FcStrSet *dirSet);
637 FcAlignSize (intptr_t size);
639 FcPrivate FcSerialize *
640 FcSerializeCreate (void);
643 FcSerializeDestroy (FcSerialize *serialize);
646 FcSerializeAlloc (FcSerialize *serialize, const void *object, int size);
649 FcSerializeReserve (FcSerialize *serialize, int size);
652 FcSerializeOffset (FcSerialize *serialize, const void *object);
655 FcSerializePtr (FcSerialize *serialize, const void *object);
658 FcLangSetSerializeAlloc (FcSerialize *serialize, const FcLangSet *l);
660 FcPrivate FcLangSet *
661 FcLangSetSerialize(FcSerialize *serialize, const FcLangSet *l);
665 FcLangCharSetPopulate (void);
667 FcPrivate FcCharSetFreezer *
668 FcCharSetFreezerCreate (void);
670 FcPrivate const FcCharSet *
671 FcCharSetFreeze (FcCharSetFreezer *freezer, const FcCharSet *fcs);
674 FcCharSetFreezerDestroy (FcCharSetFreezer *freezer);
677 FcNameUnparseCharSet (FcStrBuf *buf, const FcCharSet *c);
679 FcPrivate FcCharSet *
680 FcNameParseCharSet (FcChar8 *string);
683 FcNameUnparseValue (FcStrBuf *buf,
688 FcNameUnparseValueList (FcStrBuf *buf,
692 FcPrivate FcCharLeaf *
693 FcCharSetFindLeafCreate (FcCharSet *fcs, FcChar32 ucs4);
696 FcCharSetSerializeAlloc(FcSerialize *serialize, const FcCharSet *cs);
698 FcPrivate FcCharSet *
699 FcCharSetSerialize(FcSerialize *serialize, const FcCharSet *cs);
702 FcCharSetGetNumbers(const FcCharSet *c);
707 FcValuePrintFile (FILE *f, const FcValue v);
710 FcValuePrintWithPosition (const FcValue v, FcBool show_pos_mark);
713 FcValueListPrintWithPosition (FcValueListPtr l, const FcValueListPtr pos);
716 FcValueListPrint (FcValueListPtr l);
719 FcLangSetPrint (const FcLangSet *ls);
725 FcTestPrint (const FcTest *test);
728 FcExprPrint (const FcExpr *expr);
731 FcEditPrint (const FcEdit *edit);
734 FcSubstPrint (const FcSubst *subst);
737 FcCharSetPrint (const FcCharSet *c);
739 extern FcPrivate int FcDebugVal;
741 #define FcDebug() (FcDebugVal)
748 FcGetDefaultLang (void);
753 FcFileIsLink (const FcChar8 *file);
756 FcFileScanConfig (FcFontSet *set,
763 FcDirScanConfig (FcFontSet *set,
777 FcFontSetSerializeAlloc (FcSerialize *serialize, const FcFontSet *s);
779 FcPrivate FcFontSet *
780 FcFontSetSerialize (FcSerialize *serialize, const FcFontSet * s);
784 FcTestDestroy (FcTest *test);
787 FcEditDestroy (FcEdit *e);
790 FcPrivate FcLangSet *
791 FcFreeTypeLangSet (const FcCharSet *charset,
792 const FcChar8 *exclusiveLang);
795 FcLangNormalize (const FcChar8 *lang);
797 FcPrivate FcLangResult
798 FcLangCompare (const FcChar8 *s1, const FcChar8 *s2);
800 FcPrivate FcLangSet *
801 FcLangSetPromote (const FcChar8 *lang);
803 FcPrivate FcLangSet *
804 FcNameParseLangSet (const FcChar8 *string);
807 FcNameUnparseLangSet (FcStrBuf *buf, const FcLangSet *ls);
810 FcNameUnparseEscaped (FcPattern *pat, FcBool escape);
815 FcListPatternMatchAny (const FcPattern *p,
816 const FcPattern *font);
823 FC_INVALID_OBJECT = 0,
824 #define FC_OBJECT(NAME, Type) FC_##NAME##_OBJECT,
827 FC_ONE_AFTER_MAX_BASE_OBJECT
828 #define FC_MAX_BASE_OBJECT (FC_ONE_AFTER_MAX_BASE_OBJECT - 1)
832 FcNameBool (const FcChar8 *v, FcBool *result);
835 FcObjectValidType (FcObject object, FcType type);
838 FcObjectFromName (const char * name);
840 FcPrivate const char *
841 FcObjectName (FcObject object);
843 FcPrivate FcObjectSet *
844 FcObjectGetSet (void);
846 #define FcObjectCompare(a, b) ((int) a - (int) b)
851 FcValueCanonicalize (const FcValue *v);
853 FcPrivate FcValueListPtr
854 FcValueListCreate (void);
857 FcValueListDestroy (FcValueListPtr l);
859 FcPrivate FcValueListPtr
860 FcValueListPrepend (FcValueListPtr vallist,
862 FcValueBinding binding);
864 FcPrivate FcValueListPtr
865 FcValueListAppend (FcValueListPtr vallist,
867 FcValueBinding binding);
869 FcPrivate FcValueListPtr
870 FcValueListDuplicate(FcValueListPtr orig);
872 FcPrivate FcPatternElt *
873 FcPatternObjectFindElt (const FcPattern *p, FcObject object);
875 FcPrivate FcPatternElt *
876 FcPatternObjectInsertElt (FcPattern *p, FcObject object);
879 FcPatternObjectListAdd (FcPattern *p,
885 FcPatternObjectAddWithBinding (FcPattern *p,
888 FcValueBinding binding,
892 FcPatternObjectAdd (FcPattern *p, FcObject object, FcValue value, FcBool append);
895 FcPatternObjectAddWeak (FcPattern *p, FcObject object, FcValue value, FcBool append);
898 FcPatternObjectGet (const FcPattern *p, FcObject object, int id, FcValue *v);
901 FcPatternObjectDel (FcPattern *p, FcObject object);
904 FcPatternObjectRemove (FcPattern *p, FcObject object, int id);
907 FcPatternObjectAddInteger (FcPattern *p, FcObject object, int i);
910 FcPatternObjectAddDouble (FcPattern *p, FcObject object, double d);
913 FcPatternObjectAddString (FcPattern *p, FcObject object, const FcChar8 *s);
916 FcPatternObjectAddMatrix (FcPattern *p, FcObject object, const FcMatrix *s);
919 FcPatternObjectAddCharSet (FcPattern *p, FcObject object, const FcCharSet *c);
922 FcPatternObjectAddBool (FcPattern *p, FcObject object, FcBool b);
925 FcPatternObjectAddLangSet (FcPattern *p, FcObject object, const FcLangSet *ls);
928 FcPatternObjectGetInteger (const FcPattern *p, FcObject object, int n, int *i);
931 FcPatternObjectGetDouble (const FcPattern *p, FcObject object, int n, double *d);
934 FcPatternObjectGetString (const FcPattern *p, FcObject object, int n, FcChar8 ** s);
937 FcPatternObjectGetMatrix (const FcPattern *p, FcObject object, int n, FcMatrix **s);
940 FcPatternObjectGetCharSet (const FcPattern *p, FcObject object, int n, FcCharSet **c);
943 FcPatternObjectGetBool (const FcPattern *p, FcObject object, int n, FcBool *b);
946 FcPatternObjectGetLangSet (const FcPattern *p, FcObject object, int n, FcLangSet **ls);
949 FcPatternAppend (FcPattern *p, FcPattern *s);
951 FcPrivate const FcChar8 *
952 FcSharedStr (const FcChar8 *name);
955 FcSharedStrFree (const FcChar8 *name);
958 FcStringHash (const FcChar8 *s);
961 FcPatternSerializeAlloc (FcSerialize *serialize, const FcPattern *pat);
963 FcPrivate FcPattern *
964 FcPatternSerialize (FcSerialize *serialize, const FcPattern *pat);
967 FcValueListSerializeAlloc (FcSerialize *serialize, const FcValueList *pat);
969 FcPrivate FcValueList *
970 FcValueListSerialize (FcSerialize *serialize, const FcValueList *pat);
976 extern FcPrivate const FcMatrix FcIdentityMatrix;
979 FcMatrixFree (FcMatrix *mat);
984 FcStat (const FcChar8 *file, struct stat *statb);
987 FcStatChecksum (const FcChar8 *file, struct stat *statb);
990 FcIsFsMmapSafe (int fd);
993 FcIsFsMtimeBroken (const FcChar8 *dir);
997 FcStrSetAddLangs (FcStrSet *strs, const char *languages);
1000 FcStrSetSort (FcStrSet * set);
1003 FcStrBufInit (FcStrBuf *buf, FcChar8 *init, int size);
1006 FcStrBufDestroy (FcStrBuf *buf);
1009 FcStrBufDone (FcStrBuf *buf);
1012 FcStrBufDoneStatic (FcStrBuf *buf);
1015 FcStrBufChar (FcStrBuf *buf, FcChar8 c);
1018 FcStrBufString (FcStrBuf *buf, const FcChar8 *s);
1021 FcStrBufData (FcStrBuf *buf, const FcChar8 *s, int len);
1024 FcStrCmpIgnoreBlanksAndCase (const FcChar8 *s1, const FcChar8 *s2);
1027 FcStrRegexCmp (const FcChar8 *s, const FcChar8 *regex);
1030 FcStrRegexCmpIgnoreCase (const FcChar8 *s, const FcChar8 *regex);
1032 FcPrivate const FcChar8 *
1033 FcStrContainsIgnoreBlanksAndCase (const FcChar8 *s1, const FcChar8 *s2);
1035 FcPrivate const FcChar8 *
1036 FcStrContainsIgnoreCase (const FcChar8 *s1, const FcChar8 *s2);
1038 FcPrivate const FcChar8 *
1039 FcStrContainsWord (const FcChar8 *s1, const FcChar8 *s2);
1042 FcStrUsesHome (const FcChar8 *s);
1045 FcStrLastSlash (const FcChar8 *path);
1048 FcStrHashIgnoreCase (const FcChar8 *s);
1051 FcStrCanonFilename (const FcChar8 *s);
1054 FcStrSerializeAlloc (FcSerialize *serialize, const FcChar8 *str);
1057 FcStrSerialize (FcSerialize *serialize, const FcChar8 *str);
1062 FcObjectLookupIdByName (const char *str);
1065 FcObjectLookupBuiltinIdByName (const char *str);
1067 FcPrivate const char *
1068 FcObjectLookupOtherNameById (FcObject id);
1070 FcPrivate const FcObjectType *
1071 FcObjectLookupOtherTypeById (FcObject id);
1073 FcPrivate const FcObjectType *
1074 FcObjectLookupOtherTypeByName (const char *str);
1076 #endif /* _FC_INT_H_ */