Commit 9d5149ac authored by Akira TAGOH's avatar Akira TAGOH
Browse files

Fix FcFontList doesn't return a font with FC_COLOR=true

"color" property has a value more than 1 because the value of FT_HAS_COLOR
is directly set to it. this seems breaking the behavior of FcFontList with FC_COLOR=true
because it is more than FcDontCare.

So changing comparison that way.
parent 3c75a5a9
...@@ -821,25 +821,25 @@ FcConfigCompareValue (const FcValue *left_o, ...@@ -821,25 +821,25 @@ FcConfigCompareValue (const FcValue *left_o,
break; break;
case FcOpContains: case FcOpContains:
case FcOpListing: case FcOpListing:
ret = left.u.b == right.u.b || left.u.b == FcDontCare; ret = left.u.b == right.u.b || left.u.b >= FcDontCare;
break; break;
case FcOpNotEqual: case FcOpNotEqual:
ret = left.u.b != right.u.b; ret = left.u.b != right.u.b;
break; break;
case FcOpNotContains: case FcOpNotContains:
ret = !(left.u.b == right.u.b || left.u.b == FcDontCare); ret = !(left.u.b == right.u.b || left.u.b >= FcDontCare);
break; break;
case FcOpLess: case FcOpLess:
ret = left.u.b != right.u.b && right.u.b == FcDontCare; ret = left.u.b != right.u.b && right.u.b >= FcDontCare;
break; break;
case FcOpLessEqual: case FcOpLessEqual:
ret = left.u.b == right.u.b || right.u.b == FcDontCare; ret = left.u.b == right.u.b || right.u.b >= FcDontCare;
break; break;
case FcOpMore: case FcOpMore:
ret = left.u.b != right.u.b && left.u.b == FcDontCare; ret = left.u.b != right.u.b && left.u.b >= FcDontCare;
break; break;
case FcOpMoreEqual: case FcOpMoreEqual:
ret = left.u.b == right.u.b || left.u.b == FcDontCare; ret = left.u.b == right.u.b || left.u.b >= FcDontCare;
break; break;
default: default:
break; break;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment