<family>monospace</family>
<prefer><family>Andale Mono</family></prefer>
</alias>
+
+<--
+ The example of the requirements of OR operator;
+ If the 'family' contains 'Courier New' OR 'Courier'
+ add 'monospace' as the alternative
+-->
+<match target="pattern">
+ <test name="family" mode="eq">
+ <string>Courier New</string>
+ </test>
+ <edit name="family" mode="prepend">
+ <string>monospace</string>
+ </edit>
+</match>
+<match target="pattern">
+ <test name="family" mode="eq">
+ <string>Courier</string>
+ </test>
+ <edit name="family" mode="prepend">
+ <string>monospace</string>
+ </edit>
+</match>
+
</fontconfig>
</programlisting>
</refsect2>
case FcVStackFamily:
if (family)
{
+ FcConfigMessage (parse, FcSevereWarning, "Having multiple <family> in <alias> isn't supported and may not works as expected");
new = FcExprCreateOp (parse->config, vstack->u.expr, FcOpComma, family);
if (!new)
FcConfigMessage (parse, FcSevereError, "out of memory");
FcConfigMessage (parse, FcSevereWarning, "missing test expression");
return;
}
+ if (expr->op == FcOpComma)
+ {
+ FcConfigMessage (parse, FcSevereWarning, "Having multiple values in <test> isn't supported and may not works as expected");
+ }
test = FcTestCreate (parse, kind, qual, name, FC_OP (compare, flags), expr);
if (!test)
{