Update _FcMatchers definition logic
to make it easier to maintain. also added FC_HASH_OBJECT to be matched in the pattern, prior to FC_FILE_OBJECT.
This commit is contained in:
parent
52b2b5c992
commit
4eab908c86
|
@ -858,7 +858,7 @@ FcListPatternMatchAny (const FcPattern *p,
|
||||||
|
|
||||||
enum {
|
enum {
|
||||||
FC_INVALID_OBJECT = 0,
|
FC_INVALID_OBJECT = 0,
|
||||||
#define FC_OBJECT(NAME, Type) FC_##NAME##_OBJECT,
|
#define FC_OBJECT(NAME, Type, Cmp) FC_##NAME##_OBJECT,
|
||||||
#include "fcobjs.h"
|
#include "fcobjs.h"
|
||||||
#undef FC_OBJECT
|
#undef FC_OBJECT
|
||||||
FC_ONE_AFTER_MAX_BASE_OBJECT
|
FC_ONE_AFTER_MAX_BASE_OBJECT
|
||||||
|
|
184
src/fcmatch.c
184
src/fcmatch.c
|
@ -186,10 +186,61 @@ FcCompareFilename (FcValue *v1, FcValue *v2)
|
||||||
return 4.0;
|
return 4.0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#define PRI_NULL(n) \
|
||||||
|
PRI_ ## n ## _STRONG = -1, \
|
||||||
|
PRI_ ## n ## _WEAK = -1,
|
||||||
|
#define PRI1(n)
|
||||||
|
#define PRI_FcCompareFamily(n) PRI1(n)
|
||||||
|
#define PRI_FcCompareString(n) PRI1(n)
|
||||||
|
#define PRI_FcCompareNumber(n) PRI1(n)
|
||||||
|
#define PRI_FcCompareSize(n) PRI1(n)
|
||||||
|
#define PRI_FcCompareBool(n) PRI1(n)
|
||||||
|
#define PRI_FcCompareFilename(n) PRI1(n)
|
||||||
|
#define PRI_FcCompareCharSet(n) PRI1(n)
|
||||||
|
#define PRI_FcCompareLang(n) PRI1(n)
|
||||||
|
|
||||||
|
#define FC_OBJECT(NAME, Type, Cmp) PRI_##Cmp(NAME)
|
||||||
|
|
||||||
|
typedef enum _FcMatcherPriorityDummy {
|
||||||
|
#include "fcobjs.h"
|
||||||
|
} FcMatcherPriorityDummy;
|
||||||
|
|
||||||
|
#undef FC_OBJECT
|
||||||
|
|
||||||
|
#undef PRI1
|
||||||
|
#define PRI1(n) \
|
||||||
|
PRI_ ## n ## _STRONG, \
|
||||||
|
PRI_ ## n ## _WEAK
|
||||||
|
|
||||||
|
typedef enum _FcMatcherPriority {
|
||||||
|
PRI1(HASH),
|
||||||
|
PRI1(FILE),
|
||||||
|
PRI1(FOUNDRY),
|
||||||
|
PRI1(CHARSET),
|
||||||
|
PRI_FAMILY_STRONG,
|
||||||
|
PRI_LANG_STRONG,
|
||||||
|
PRI_LANG_WEAK,
|
||||||
|
PRI_FAMILY_WEAK,
|
||||||
|
PRI1(SPACING),
|
||||||
|
PRI1(PIXEL_SIZE),
|
||||||
|
PRI1(STYLE),
|
||||||
|
PRI1(SLANT),
|
||||||
|
PRI1(WEIGHT),
|
||||||
|
PRI1(WIDTH),
|
||||||
|
PRI1(DECORATIVE),
|
||||||
|
PRI1(ANTIALIAS),
|
||||||
|
PRI1(RASTERIZER),
|
||||||
|
PRI1(OUTLINE),
|
||||||
|
PRI1(FONTVERSION),
|
||||||
|
PRI_END
|
||||||
|
} FcMatcherPriority;
|
||||||
|
|
||||||
|
#undef PRI1
|
||||||
|
|
||||||
typedef struct _FcMatcher {
|
typedef struct _FcMatcher {
|
||||||
FcObject object;
|
FcObject object;
|
||||||
double (*compare) (FcValue *value1, FcValue *value2);
|
double (*compare) (FcValue *value1, FcValue *value2);
|
||||||
int strong, weak;
|
int strong, weak;
|
||||||
} FcMatcher;
|
} FcMatcher;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
@ -197,100 +248,33 @@ typedef struct _FcMatcher {
|
||||||
* each value, earlier values are more significant than
|
* each value, earlier values are more significant than
|
||||||
* later values
|
* later values
|
||||||
*/
|
*/
|
||||||
|
#define FC_OBJECT(NAME, Type, Cmp) { FC_##NAME##_OBJECT, Cmp, PRI_##NAME##_STRONG, PRI_##NAME##_WEAK },
|
||||||
static const FcMatcher _FcMatchers [] = {
|
static const FcMatcher _FcMatchers [] = {
|
||||||
{ FC_FILE_OBJECT, FcCompareFilename, 0, 0 },
|
{ FC_INVALID_OBJECT, NULL, -1, -1 },
|
||||||
#define MATCH_FILE 0
|
#include "fcobjs.h"
|
||||||
{ FC_FOUNDRY_OBJECT, FcCompareString, 1, 1 },
|
|
||||||
#define MATCH_FOUNDRY 1
|
|
||||||
{ FC_CHARSET_OBJECT, FcCompareCharSet, 2, 2 },
|
|
||||||
#define MATCH_CHARSET 2
|
|
||||||
{ FC_FAMILY_OBJECT, FcCompareFamily, 3, 5 },
|
|
||||||
#define MATCH_FAMILY 3
|
|
||||||
{ FC_LANG_OBJECT, FcCompareLang, 4, 4 },
|
|
||||||
#define MATCH_LANG 4
|
|
||||||
#define MATCH_LANG_INDEX 4
|
|
||||||
{ FC_SPACING_OBJECT, FcCompareNumber, 6, 6 },
|
|
||||||
#define MATCH_SPACING 5
|
|
||||||
{ FC_PIXEL_SIZE_OBJECT, FcCompareSize, 7, 7 },
|
|
||||||
#define MATCH_PIXEL_SIZE 6
|
|
||||||
{ FC_STYLE_OBJECT, FcCompareString, 8, 8 },
|
|
||||||
#define MATCH_STYLE 7
|
|
||||||
{ FC_SLANT_OBJECT, FcCompareNumber, 9, 9 },
|
|
||||||
#define MATCH_SLANT 8
|
|
||||||
{ FC_WEIGHT_OBJECT, FcCompareNumber, 10, 10 },
|
|
||||||
#define MATCH_WEIGHT 9
|
|
||||||
{ FC_WIDTH_OBJECT, FcCompareNumber, 11, 11 },
|
|
||||||
#define MATCH_WIDTH 10
|
|
||||||
{ FC_DECORATIVE_OBJECT, FcCompareBool, 12, 12 },
|
|
||||||
#define MATCH_DECORATIVE 11
|
|
||||||
{ FC_ANTIALIAS_OBJECT, FcCompareBool, 13, 13 },
|
|
||||||
#define MATCH_ANTIALIAS 12
|
|
||||||
{ FC_RASTERIZER_OBJECT, FcCompareString, 14, 14 },
|
|
||||||
#define MATCH_RASTERIZER 13
|
|
||||||
{ FC_OUTLINE_OBJECT, FcCompareBool, 15, 15 },
|
|
||||||
#define MATCH_OUTLINE 14
|
|
||||||
{ FC_FONTVERSION_OBJECT, FcCompareNumber, 16, 16 },
|
|
||||||
#define MATCH_FONTVERSION 15
|
|
||||||
};
|
};
|
||||||
|
#undef FC_OBJECT
|
||||||
#define NUM_MATCH_VALUES 17
|
|
||||||
|
|
||||||
static const FcMatcher*
|
static const FcMatcher*
|
||||||
FcObjectToMatcher (FcObject object,
|
FcObjectToMatcher (FcObject object,
|
||||||
FcBool include_lang)
|
FcBool include_lang)
|
||||||
{
|
{
|
||||||
int i;
|
if (include_lang)
|
||||||
|
{
|
||||||
i = -1;
|
switch (object) {
|
||||||
switch (object) {
|
case FC_FAMILYLANG_OBJECT:
|
||||||
case FC_FILE_OBJECT:
|
case FC_STYLELANG_OBJECT:
|
||||||
i = MATCH_FILE; break;
|
case FC_FULLNAMELANG_OBJECT:
|
||||||
case FC_FOUNDRY_OBJECT:
|
object = FC_LANG_OBJECT;
|
||||||
i = MATCH_FOUNDRY; break;
|
break;
|
||||||
case FC_FONTVERSION_OBJECT:
|
|
||||||
i = MATCH_FONTVERSION; break;
|
|
||||||
case FC_FAMILY_OBJECT:
|
|
||||||
i = MATCH_FAMILY; break;
|
|
||||||
case FC_CHARSET_OBJECT:
|
|
||||||
i = MATCH_CHARSET; break;
|
|
||||||
case FC_ANTIALIAS_OBJECT:
|
|
||||||
i = MATCH_ANTIALIAS; break;
|
|
||||||
case FC_LANG_OBJECT:
|
|
||||||
i = MATCH_LANG; break;
|
|
||||||
case FC_SPACING_OBJECT:
|
|
||||||
i = MATCH_SPACING; break;
|
|
||||||
case FC_STYLE_OBJECT:
|
|
||||||
i = MATCH_STYLE; break;
|
|
||||||
case FC_SLANT_OBJECT:
|
|
||||||
i = MATCH_SLANT; break;
|
|
||||||
case FC_PIXEL_SIZE_OBJECT:
|
|
||||||
i = MATCH_PIXEL_SIZE; break;
|
|
||||||
case FC_WIDTH_OBJECT:
|
|
||||||
i = MATCH_WIDTH; break;
|
|
||||||
case FC_WEIGHT_OBJECT:
|
|
||||||
i = MATCH_WEIGHT; break;
|
|
||||||
case FC_RASTERIZER_OBJECT:
|
|
||||||
i = MATCH_RASTERIZER; break;
|
|
||||||
case FC_OUTLINE_OBJECT:
|
|
||||||
i = MATCH_OUTLINE; break;
|
|
||||||
case FC_DECORATIVE_OBJECT:
|
|
||||||
i = MATCH_DECORATIVE; break;
|
|
||||||
default:
|
|
||||||
if (include_lang)
|
|
||||||
{
|
|
||||||
switch (object) {
|
|
||||||
case FC_FAMILYLANG_OBJECT:
|
|
||||||
case FC_STYLELANG_OBJECT:
|
|
||||||
case FC_FULLNAMELANG_OBJECT:
|
|
||||||
i = MATCH_LANG; break;
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (!_FcMatchers[object].compare ||
|
||||||
if (i < 0)
|
_FcMatchers[object].strong == -1 ||
|
||||||
|
_FcMatchers[object].weak == -1)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
return _FcMatchers+i;
|
return _FcMatchers + object;
|
||||||
}
|
}
|
||||||
|
|
||||||
static FcBool
|
static FcBool
|
||||||
|
@ -390,7 +374,7 @@ FcCompare (FcPattern *pat,
|
||||||
{
|
{
|
||||||
int i, i1, i2;
|
int i, i1, i2;
|
||||||
|
|
||||||
for (i = 0; i < NUM_MATCH_VALUES; i++)
|
for (i = 0; i < PRI_END; i++)
|
||||||
value[i] = 0.0;
|
value[i] = 0.0;
|
||||||
|
|
||||||
i1 = 0;
|
i1 = 0;
|
||||||
|
@ -565,14 +549,14 @@ FcFontSetMatchInternal (FcFontSet **sets,
|
||||||
FcPattern *p,
|
FcPattern *p,
|
||||||
FcResult *result)
|
FcResult *result)
|
||||||
{
|
{
|
||||||
double score[NUM_MATCH_VALUES], bestscore[NUM_MATCH_VALUES];
|
double score[PRI_END], bestscore[PRI_END];
|
||||||
int f;
|
int f;
|
||||||
FcFontSet *s;
|
FcFontSet *s;
|
||||||
FcPattern *best;
|
FcPattern *best;
|
||||||
int i;
|
int i;
|
||||||
int set;
|
int set;
|
||||||
|
|
||||||
for (i = 0; i < NUM_MATCH_VALUES; i++)
|
for (i = 0; i < PRI_END; i++)
|
||||||
bestscore[i] = 0;
|
bestscore[i] = 0;
|
||||||
best = 0;
|
best = 0;
|
||||||
if (FcDebug () & FC_DBG_MATCH)
|
if (FcDebug () & FC_DBG_MATCH)
|
||||||
|
@ -597,19 +581,19 @@ FcFontSetMatchInternal (FcFontSet **sets,
|
||||||
if (FcDebug () & FC_DBG_MATCHV)
|
if (FcDebug () & FC_DBG_MATCHV)
|
||||||
{
|
{
|
||||||
printf ("Score");
|
printf ("Score");
|
||||||
for (i = 0; i < NUM_MATCH_VALUES; i++)
|
for (i = 0; i < PRI_END; i++)
|
||||||
{
|
{
|
||||||
printf (" %g", score[i]);
|
printf (" %g", score[i]);
|
||||||
}
|
}
|
||||||
printf ("\n");
|
printf ("\n");
|
||||||
}
|
}
|
||||||
for (i = 0; i < NUM_MATCH_VALUES; i++)
|
for (i = 0; i < PRI_END; i++)
|
||||||
{
|
{
|
||||||
if (best && bestscore[i] < score[i])
|
if (best && bestscore[i] < score[i])
|
||||||
break;
|
break;
|
||||||
if (!best || score[i] < bestscore[i])
|
if (!best || score[i] < bestscore[i])
|
||||||
{
|
{
|
||||||
for (i = 0; i < NUM_MATCH_VALUES; i++)
|
for (i = 0; i < PRI_END; i++)
|
||||||
bestscore[i] = score[i];
|
bestscore[i] = score[i];
|
||||||
best = s->fonts[f];
|
best = s->fonts[f];
|
||||||
break;
|
break;
|
||||||
|
@ -620,7 +604,7 @@ FcFontSetMatchInternal (FcFontSet **sets,
|
||||||
if (FcDebug () & FC_DBG_MATCH)
|
if (FcDebug () & FC_DBG_MATCH)
|
||||||
{
|
{
|
||||||
printf ("Best score");
|
printf ("Best score");
|
||||||
for (i = 0; i < NUM_MATCH_VALUES; i++)
|
for (i = 0; i < PRI_END; i++)
|
||||||
printf (" %g", bestscore[i]);
|
printf (" %g", bestscore[i]);
|
||||||
printf ("\n");
|
printf ("\n");
|
||||||
FcPatternPrint (best);
|
FcPatternPrint (best);
|
||||||
|
@ -696,7 +680,7 @@ FcFontMatch (FcConfig *config,
|
||||||
|
|
||||||
typedef struct _FcSortNode {
|
typedef struct _FcSortNode {
|
||||||
FcPattern *pattern;
|
FcPattern *pattern;
|
||||||
double score[NUM_MATCH_VALUES];
|
double score[PRI_END];
|
||||||
} FcSortNode;
|
} FcSortNode;
|
||||||
|
|
||||||
static int
|
static int
|
||||||
|
@ -709,7 +693,7 @@ FcSortCompare (const void *aa, const void *ab)
|
||||||
double ad = 0, bd = 0;
|
double ad = 0, bd = 0;
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
i = NUM_MATCH_VALUES;
|
i = PRI_END;
|
||||||
while (i-- && (ad = *as++) == (bd = *bs++))
|
while (i-- && (ad = *as++) == (bd = *bs++))
|
||||||
;
|
;
|
||||||
return ad < bd ? -1 : ad > bd ? 1 : 0;
|
return ad < bd ? -1 : ad > bd ? 1 : 0;
|
||||||
|
@ -874,7 +858,7 @@ FcFontSetSort (FcConfig *config FC_UNUSED,
|
||||||
if (FcDebug () & FC_DBG_MATCHV)
|
if (FcDebug () & FC_DBG_MATCHV)
|
||||||
{
|
{
|
||||||
printf ("Score");
|
printf ("Score");
|
||||||
for (i = 0; i < NUM_MATCH_VALUES; i++)
|
for (i = 0; i < PRI_END; i++)
|
||||||
{
|
{
|
||||||
printf (" %g", new->score[i]);
|
printf (" %g", new->score[i]);
|
||||||
}
|
}
|
||||||
|
@ -901,7 +885,8 @@ FcFontSetSort (FcConfig *config FC_UNUSED,
|
||||||
* If this node matches any language, go check
|
* If this node matches any language, go check
|
||||||
* which ones and satisfy those entries
|
* which ones and satisfy those entries
|
||||||
*/
|
*/
|
||||||
if (nodeps[f]->score[MATCH_LANG_INDEX] < 2000)
|
if (nodeps[f]->score[PRI_LANG_STRONG] < 2000 ||
|
||||||
|
nodeps[f]->score[PRI_LANG_WEAK] < 2000)
|
||||||
{
|
{
|
||||||
for (i = 0; i < nPatternLang; i++)
|
for (i = 0; i < nPatternLang; i++)
|
||||||
{
|
{
|
||||||
|
@ -931,7 +916,10 @@ FcFontSetSort (FcConfig *config FC_UNUSED,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!satisfies)
|
if (!satisfies)
|
||||||
nodeps[f]->score[MATCH_LANG_INDEX] = 10000.0;
|
{
|
||||||
|
nodeps[f]->score[PRI_LANG_STRONG] = 10000.0;
|
||||||
|
nodeps[f]->score[PRI_LANG_WEAK] = 10000.0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -29,7 +29,7 @@
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
static const FcObjectType FcObjects[] = {
|
static const FcObjectType FcObjects[] = {
|
||||||
#define FC_OBJECT(NAME, Type) { FC_##NAME, Type },
|
#define FC_OBJECT(NAME, Type, Cmp) { FC_##NAME, Type },
|
||||||
#include "fcobjs.h"
|
#include "fcobjs.h"
|
||||||
#undef FC_OBJECT
|
#undef FC_OBJECT
|
||||||
};
|
};
|
||||||
|
|
90
src/fcobjs.h
90
src/fcobjs.h
|
@ -1,47 +1,47 @@
|
||||||
/* DON'T REORDER! The order is part of the cache signature. */
|
/* DON'T REORDER! The order is part of the cache signature. */
|
||||||
FC_OBJECT (FAMILY, FcTypeString)
|
FC_OBJECT (FAMILY, FcTypeString, FcCompareFamily)
|
||||||
FC_OBJECT (FAMILYLANG, FcTypeString)
|
FC_OBJECT (FAMILYLANG, FcTypeString, NULL)
|
||||||
FC_OBJECT (STYLE, FcTypeString)
|
FC_OBJECT (STYLE, FcTypeString, FcCompareString)
|
||||||
FC_OBJECT (STYLELANG, FcTypeString)
|
FC_OBJECT (STYLELANG, FcTypeString, NULL)
|
||||||
FC_OBJECT (FULLNAME, FcTypeString)
|
FC_OBJECT (FULLNAME, FcTypeString, NULL)
|
||||||
FC_OBJECT (FULLNAMELANG, FcTypeString)
|
FC_OBJECT (FULLNAMELANG, FcTypeString, NULL)
|
||||||
FC_OBJECT (SLANT, FcTypeInteger)
|
FC_OBJECT (SLANT, FcTypeInteger, FcCompareNumber)
|
||||||
FC_OBJECT (WEIGHT, FcTypeInteger)
|
FC_OBJECT (WEIGHT, FcTypeInteger, FcCompareNumber)
|
||||||
FC_OBJECT (WIDTH, FcTypeInteger)
|
FC_OBJECT (WIDTH, FcTypeInteger, FcCompareNumber)
|
||||||
FC_OBJECT (SIZE, FcTypeDouble)
|
FC_OBJECT (SIZE, FcTypeDouble, NULL)
|
||||||
FC_OBJECT (ASPECT, FcTypeDouble)
|
FC_OBJECT (ASPECT, FcTypeDouble, NULL)
|
||||||
FC_OBJECT (PIXEL_SIZE, FcTypeDouble)
|
FC_OBJECT (PIXEL_SIZE, FcTypeDouble, FcCompareSize)
|
||||||
FC_OBJECT (SPACING, FcTypeInteger)
|
FC_OBJECT (SPACING, FcTypeInteger, FcCompareNumber)
|
||||||
FC_OBJECT (FOUNDRY, FcTypeString)
|
FC_OBJECT (FOUNDRY, FcTypeString, FcCompareString)
|
||||||
FC_OBJECT (ANTIALIAS, FcTypeBool)
|
FC_OBJECT (ANTIALIAS, FcTypeBool, FcCompareBool)
|
||||||
FC_OBJECT (HINT_STYLE, FcTypeInteger)
|
FC_OBJECT (HINT_STYLE, FcTypeInteger, NULL)
|
||||||
FC_OBJECT (HINTING, FcTypeBool)
|
FC_OBJECT (HINTING, FcTypeBool, NULL)
|
||||||
FC_OBJECT (VERTICAL_LAYOUT, FcTypeBool)
|
FC_OBJECT (VERTICAL_LAYOUT, FcTypeBool, NULL)
|
||||||
FC_OBJECT (AUTOHINT, FcTypeBool)
|
FC_OBJECT (AUTOHINT, FcTypeBool, NULL)
|
||||||
FC_OBJECT (GLOBAL_ADVANCE, FcTypeBool) /* deprecated */
|
FC_OBJECT (GLOBAL_ADVANCE, FcTypeBool, NULL) /* deprecated */
|
||||||
FC_OBJECT (FILE, FcTypeString)
|
FC_OBJECT (FILE, FcTypeString, FcCompareFilename)
|
||||||
FC_OBJECT (INDEX, FcTypeInteger)
|
FC_OBJECT (INDEX, FcTypeInteger, NULL)
|
||||||
FC_OBJECT (RASTERIZER, FcTypeString)
|
FC_OBJECT (RASTERIZER, FcTypeString, FcCompareString)
|
||||||
FC_OBJECT (OUTLINE, FcTypeBool)
|
FC_OBJECT (OUTLINE, FcTypeBool, FcCompareBool)
|
||||||
FC_OBJECT (SCALABLE, FcTypeBool)
|
FC_OBJECT (SCALABLE, FcTypeBool, NULL)
|
||||||
FC_OBJECT (DPI, FcTypeDouble)
|
FC_OBJECT (DPI, FcTypeDouble, NULL)
|
||||||
FC_OBJECT (RGBA, FcTypeInteger)
|
FC_OBJECT (RGBA, FcTypeInteger, NULL)
|
||||||
FC_OBJECT (SCALE, FcTypeDouble)
|
FC_OBJECT (SCALE, FcTypeDouble, NULL)
|
||||||
FC_OBJECT (MINSPACE, FcTypeBool)
|
FC_OBJECT (MINSPACE, FcTypeBool, NULL)
|
||||||
FC_OBJECT (CHAR_WIDTH, FcTypeInteger)
|
FC_OBJECT (CHAR_WIDTH, FcTypeInteger, NULL)
|
||||||
FC_OBJECT (CHAR_HEIGHT, FcTypeInteger)
|
FC_OBJECT (CHAR_HEIGHT, FcTypeInteger, NULL)
|
||||||
FC_OBJECT (MATRIX, FcTypeMatrix)
|
FC_OBJECT (MATRIX, FcTypeMatrix, NULL)
|
||||||
FC_OBJECT (CHARSET, FcTypeCharSet)
|
FC_OBJECT (CHARSET, FcTypeCharSet, FcCompareCharSet)
|
||||||
FC_OBJECT (LANG, FcTypeLangSet)
|
FC_OBJECT (LANG, FcTypeLangSet, FcCompareLang)
|
||||||
FC_OBJECT (FONTVERSION, FcTypeInteger)
|
FC_OBJECT (FONTVERSION, FcTypeInteger, FcCompareNumber)
|
||||||
FC_OBJECT (CAPABILITY, FcTypeString)
|
FC_OBJECT (CAPABILITY, FcTypeString, NULL)
|
||||||
FC_OBJECT (FONTFORMAT, FcTypeString)
|
FC_OBJECT (FONTFORMAT, FcTypeString, NULL)
|
||||||
FC_OBJECT (EMBOLDEN, FcTypeBool)
|
FC_OBJECT (EMBOLDEN, FcTypeBool, NULL)
|
||||||
FC_OBJECT (EMBEDDED_BITMAP, FcTypeBool)
|
FC_OBJECT (EMBEDDED_BITMAP, FcTypeBool, NULL)
|
||||||
FC_OBJECT (DECORATIVE, FcTypeBool)
|
FC_OBJECT (DECORATIVE, FcTypeBool, FcCompareBool)
|
||||||
FC_OBJECT (LCD_FILTER, FcTypeInteger)
|
FC_OBJECT (LCD_FILTER, FcTypeInteger, NULL)
|
||||||
FC_OBJECT (NAMELANG, FcTypeString)
|
FC_OBJECT (NAMELANG, FcTypeString, NULL)
|
||||||
FC_OBJECT (FONT_FEATURES, FcTypeString)
|
FC_OBJECT (FONT_FEATURES, FcTypeString, NULL)
|
||||||
FC_OBJECT (PRGNAME, FcTypeString)
|
FC_OBJECT (PRGNAME, FcTypeString, NULL)
|
||||||
FC_OBJECT (HASH, FcTypeString)
|
FC_OBJECT (HASH, FcTypeString, FcCompareString)
|
||||||
/* ^-------------- Add new objects here. */
|
/* ^-------------- Add new objects here. */
|
||||||
|
|
|
@ -21,6 +21,6 @@ struct FcObjectTypeInfo {
|
||||||
};
|
};
|
||||||
|
|
||||||
%%
|
%%
|
||||||
#define FC_OBJECT(NAME, Type) FC_##NAME, FC_##NAME##_OBJECT
|
#define FC_OBJECT(NAME, Type, Cmp) FC_##NAME, FC_##NAME##_OBJECT
|
||||||
#include "fcobjs.h"
|
#include "fcobjs.h"
|
||||||
#undef FC_OBJECT
|
#undef FC_OBJECT
|
||||||
|
|
Loading…
Reference in New Issue