[HarfBuzz] [PATCH] Added an Indic shaper
Jonathan Kew
jonathan at jfkew.plus.com
Thu Apr 21 07:54:12 PDT 2011
On 21 Apr 2011, at 15:48, Tom Hacohen wrote:
> Dear all,
>
> Thanks to Olivier Berten who let me know that all I need is to tell hb
> which opentype features I want to use in order for Indic to work, I got
> Indic scripts to work.
>
> As said before, I can't read these languages, but from what I have seen,
> it works like a charm. I just took the list of features used in
> Harfbuzz.old and hacked together an Indic shaper.
>
> Attached is a patch implementing that shaper.
>
> I don't know if adding those features is really enough, nor am I sure
> they need to be applied on all the scripts I applied them all, but this
> patch gets the job done. It's now roughly the same as the Arabic shaper.
>
> Let me know if you have any comments.
I'm afraid this is _not_ sufficient to get correct rendering of most (all?) Indic scripts. In addition to the application of OpenType features, Indic scripts require reordering of certain characters; for example, some vowel marks such as the Devanagari short I are encoded following a consonant (cluster) but must be reordered before it for rendering. OpenType features do not handle this; it is the responsibility of the shaping engine.
Also, some of the OT features need to be applied selectively only to certain characters within the Indic syllable, not indiscriminately to all the text.
JK
More information about the HarfBuzz
mailing list