[coretext] Fully support user features
authorBehdad Esfahbod <behdad@behdad.org>
Mon, 12 Aug 2013 04:33:28 +0000 (00:33 -0400)
committerBehdad Esfahbod <behdad@behdad.org>
Mon, 12 Aug 2013 16:01:05 +0000 (12:01 -0400)
commit3613696b57225111507a3f4263f5fa6937d0bc72
tree1cef82e54c19d3c3c099ac1dfa5c94e904cd8107
parent54e6f6c588a164f7de62ff88b3eff4f25adb8f17
[coretext] Fully support user features

Based on patch from Jonathan Kew and data from Apple.

It's not working correctly though, and I suspect I'm hitting a bug in
CoreText.  When I do this:

hb-shape /Library/Fonts/Zapfino.ttf ZapfinoZapfino --shaper coretext \
--features=-liga

I expect both ligatures to turn off, but only the second one does:

[Z_a_p_f_i_n_o=0+2333|Z=7+395|a=8+285|p_f=9+433|i=11+181|n=12+261|o=13+250]

whereas if I disable 'dlig' instead of 'liga', both are turned off.
Smells...

Doesn't resolve conflicting feature settings.
src/hb-coretext.cc
src/hb-uniscribe.cc