<div dir="ltr">The problem is, we currently go through Fontconfig, which doesn't support variation selectors either. Need to either bypass that and go to FreeType or HarfBuzz directly, or fix Fontconfig first...<br></div><div class="gmail_extra"><br><div class="gmail_quote">On Fri, Aug 11, 2017 at 3:16 PM, Behdad Esfahbod <span dir="ltr"><<a href="mailto:behdad@cs.toronto.edu" target="_blank">behdad@cs.toronto.edu</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div><div>Ouch...<br></div>Pango doesn't support variation selectors yet... The missing line is in pangofc-shape.c:<br><br>static hb_font_funcs_t * <br>pango_fc_get_hb_font_funcs (void) <br>{ <br> static hb_font_funcs_t *funcs; <br> <br> if (G_UNLIKELY (!funcs)) { <br> funcs = hb_font_funcs_create (); <br> hb_font_funcs_set_nominal_<wbr>glyph_func (funcs, pango_fc_hb_font_get_nominal_<wbr>glyph, NULL, NULL); <br> /* XXX we don't support variation selectors yet :(. */ <br><br></div>Let me think about what's the easiest way to fix that.<br></div><div class="gmail_extra"><div><div class="h5"><br><div class="gmail_quote">On Fri, Aug 11, 2017 at 3:09 PM, Matthias Clasen <span dir="ltr"><<a href="mailto:matthias.clasen@gmail.com" target="_blank">matthias.clasen@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><br><div class="gmail_extra">I've been down many dead ends here. What I am looking at currently is this:<br><br>$ ./hb-unicode-encode 1f468 200D 2695 fe0f | ../../util/hb-shape --show-unicode /usr/share/fonts/google-noto-e<wbr>moji/NotoColorEmoji.ttf <br><U+1F468,U+200D,U+2695,U+FE0F><br>[gid1586=0+2550]<br><br></div><div class="gmail_extra">hb-shape shapes the "man health worker" sequence to a single glyph, as expected<br></div><div class="gmail_extra">My debug spew from inside pango shows this:<br><br>hb shape font: Noto Color Emoji 81.75<br>calling hb shape: item text: 👨⚕️<br>unicode: 1f468 200d 2695 fe0f<br>hb shape output: 2 glyphs: 1586 3<br><br></div><div class="gmail_extra">Same input sequence, but an extra glyph is produced. Do you have any idea why this happens ?<br><br>Not sure yet how that messes up the rendering in cairo later<br></div></div>
</blockquote></div><br><br clear="all"><br></div></div><span class="HOEnZb"><font color="#888888">-- <br><div class="m_-2746211418675333287gmail_signature" data-smartmail="gmail_signature">behdad<br><a href="http://behdad.org/" target="_blank">http://behdad.org/</a></div>
</font></span></div>
</blockquote></div><br><br clear="all"><br>-- <br><div class="gmail_signature" data-smartmail="gmail_signature">behdad<br><a href="http://behdad.org/" target="_blank">http://behdad.org/</a></div>
</div>