Lines Matching defs:object
48 * FcPatterns are {objectName -> [element]} (maps from object names to a list of elements).
121 static bool get_bool(FcPattern* pattern, const char object[], bool missing = false) {
123 if (FcPatternGetBool(pattern, object, 0, &value) != FcResultMatch) {
129 static int get_int(FcPattern* pattern, const char object[], int missing) {
131 if (FcPatternGetInteger(pattern, object, 0, &value) != FcResultMatch) {
137 static const char* get_string(FcPattern* pattern, const char object[], const char* missing = "") {
139 if (FcPatternGetString(pattern, object, 0, &value) != FcResultMatch) {
145 static const FcMatrix* get_matrix(FcPattern* pattern, const char object[]) {
147 if (FcPatternGetMatrix(pattern, object, 0, &matrix) != FcResultMatch) {
159 * FcResult FcPatternIsWeak(pattern, object, id, FcBool* isWeak);
164 * The weak bit only affects the matching of FC_FAMILY and FC_POSTSCRIPT_NAME object values.
168 static SkWeakReturn is_weak(FcPattern* pattern, const char object[], int id) {
173 // Create a copy of the pattern with only the value 'pattern'['object'['id']] in it.
175 SkAutoFcObjectSet requestedObjectOnly(FcObjectSetBuild(object, nullptr));
179 hasId = FcPatternRemove(minimal, object, 0);
185 result = FcPatternGet(minimal, object, 0, &value);
190 hasId = FcPatternRemove(minimal, object, 1);
194 // 1. the same 'object' as minimal and a lang object with only 'nomatchlang'.
195 // 2. a different 'object' from minimal and a lang object with only 'matchlang'.
206 FcPatternAddString(weak, object, (const FcChar8*)"nomatchstring");
236 static void remove_weak(FcPattern* pattern, const char object[]) {
239 SkAutoFcObjectSet requestedObjectOnly(FcObjectSetBuild(object, nullptr));
246 result = is_weak(minimal, object, 0);
254 SkAssertResult(FcPatternRemove(minimal, object, 0));
264 SkAssertResult(FcPatternRemove(pattern, object, lastStrongId + 1));
744 /** True if any string object value in the font is the same
745 * as a string object value in the pattern.
747 static bool AnyMatching(FcPattern* font, FcPattern* pattern, const char* object) {
751 // Set an arbitrary limit on the number of pattern object values to consider.
755 result = FcPatternGetString(pattern, object, patternId, &patternString);
763 result = FcPatternGetString(font, object, fontId, &fontString);