GlyphID reverse lookup to get Unicode characters
In my plug-in I have a GlyphID extracted from an IPMFont* but the glyph does not have a unicode value because it is a ligature, a combination of many unicode characters. Is there a way I can query the IPMFont* object to find out what unicode characters need to be used to convert to this ligature. In a TrueType font this information would be held in the 'GSUB' (Glyph SUBstitution) table.
a simple example of this would be:
'f' + 'f' + 'i' = 'ffi'
'1' + '/' + '2' = '½'
So the glyphID I have would be the 'ffi' or the '½' glyph and I need to find out the 3 unicode characters which, when used in combination, would cause that glyph to be used.
This is then extended to Arabic and Hindi fonts where the Ligatures are highly important in drawing the script correctly.
Using Utils<IGlyphUtils>->GlyphToCharacter (font, glyph, &userAreaChar) does not work as the glyph has no Unicode character representation so the function just returns 0.
Likewise Utils<IGlyphUtils>->GetUnicodeForGlyphID (font, glyph) gives the same result