google-chromefontsopentypeligature

Browser font ligature rendering - Ligatures between θ and latin characters not working


I'm working on a WOFF2 font using FontForge. All ligatures render correctly in Chrome, except those defined between θ and latin vowels which always appear as separate characters.

The ligatures are defined in the GSUB table with feature 'liga' and scripts "DFLT{dflt} latn{dflt} grek{dflt}". The ligatures render as expected in the Metrics preview in Fontforge, just not when compiled as WOFF2 and used in Chrome.

If I do nothing other than change the character θ to a latin character, the ligatures appear as expected, so my working theory is that the issue is due to the fact that θ is the only character defined by Unicode as being in the Greek range whereas all other ligatures are between characters defined as latin. Can anyone explain this behaviour or offer a solution?

One option is to replace the character θ with a latin character, but this breaks IPA support somewhat so is undesireable, so I would much rather find a method of allowing Chrome to recognise such ligatures (e.g. "θu").


Solution

  • Having spoken to one of the developers at HarfBuzz, it turns out that this simply can't be done in Chrome because the text from different scripts will be separated into different runs before being passed to HB for rendering and thus such a ligature will never be triggered.

    The solution for now will be to use T instead of θ.