Prefer color emoji fonts

This commit is contained in:
Kovid Goyal 2017-12-07 10:12:20 +05:30
parent ef6f4c2fbf
commit f3cdf4194a
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C

View File

@ -195,6 +195,7 @@ create_fallback_face(PyObject UNUSED *base_face, Cell* cell, bool bold, bool ita
AP(FcPatternAddString, FC_FAMILY, (const FcChar8*)(emoji ? "emoji" : "monospace"), "family");
if (!emoji && bold) { AP(FcPatternAddInteger, FC_WEIGHT, FC_WEIGHT_BOLD, "weight"); }
if (!emoji && italic) { AP(FcPatternAddInteger, FC_SLANT, FC_SLANT_ITALIC, "slant"); }
if (emoji) { AP(FcPatternAddBool, FC_COLOR, true, "color"); }
size_t num = cell_as_unicode(cell, true, char_buf, ' ');
add_charset(pat, num);
PyObject *d = _fc_match(pat);