[HarfBuzz] [Harfbuzz] Issue in Malayalam String Rendering

Behdad Esfahbod behdad at behdad.org
Sun Oct 26 18:09:47 PDT 2014


I can't follow what's being reported.  Please file an issue on github and try
to explain more clearly what you are trying to do, what happens and what you
think should happen.  No need to show code modifications.  We need to
understand the logic and assess that.  I doubt we can change anything like
this since our goal is to match Uniscribe closely in general.

behdad

On 14-09-15 08:00 PM, Suresh P. wrote:
> I doubt this mod will end up in the a regression of positioning prebase matra
> in front of ligated cillu. I have seen Uniscribe too disregarding the pres
> rules. Not sure about its present status.
> 
> -suresh
> 
> On 11 September 2014 14:36:37 GMT+05:30, Uvaraja Pandian <p.uvaraja at gmail.com>
> wrote:
> 
>     Hi  Team,____
> 
>     __ __
> 
>     We are using the Harfbuzz 0.9.34 version.____
> 
>     __ __
> 
>     While rendering the Malayalam string using the Harfbuzz and Freetype
>     engine, we see some issues.____
> 
>     __ __
> 
>     *String used: *ക്കേ____
> 
>     *Unicode value:* 0x0d15, 0x0d4d, 0x0d15, 0x0d47, 0x0000 ____
> 
>     __ __
> 
>     *Harfbuzz Output:____*
> 
>     ____
> 
>     __ __
> 
>     *Proper Output :____*
> 
>     ____
> 
>     __ __
> 
>     *Font File used:* Akruti Family, Since this is a licensed font file, we
>     are not able to share it.
> 
>     __ __
> 
>     *Issue in Detail:____*
> 
>     __ __
> 
>     In the font file,____
> 
>     script mlym {____
> 
>       # Malayalam____
> 
>       feature Akhands;____
> 
>       feature BelowBaseSubstitutions;____
> 
>       feature *HalfForms*;____
> 
>       feature PostBaseForms;____
> 
>       feature PostBaseSubstitutions;____
> 
>       feature *PreBaseSubstitutions*;____
> 
>     }____
> 
>     __ __
> 
>     As per the Harfbuzz implementation, below substitution is happening as
>     part of the HalfForms ,____
> 
>     0x0d15 & 0x0d4d è XYZ character,____
> 
>     __ __
> 
>     so the output is XYZ, 0x0d15, 0x0d47____
> 
>     __ __
> 
>     Final re-ordering happens and rearranges as below,____
> 
>     XYZ, 0x0d15, 0x0d47 è XYZ, 0x0d47, 0x0d15____
> 
>     __ __
> 
>     As per the PreBaseSubstitutions,____
> 
>     XYZ & 0x0d15 is not matched and the output is not proper.____
> 
>     __ __
> 
>     In-Order to solve this issue, below changes has been done,____
> 
>     __ __
> 
>     Final Re-ordering,____
> 
>     PSB for the code changes____
> 
>     __ __
> 
>     As per the PreBaseSubstitutions,____
> 
>     XYZ & 0x0d15 forms the final character.____
> 
>     __ __
> 
>     *Code Modifications:____*
> 
>     In the file hb-ot-shape-complex-indic.cc, if we modify the lines as below
>     in the function final_reordering_syllable() it is working,____
> 
>     __ __
> 
>       if (start + 1 < end && start < base) /* Otherwise there can't be any
>     pre-base matra characters. */____
> 
>       {____
> 
>               /* If we lost track of base, alas, position before last thingy.
>     */____
> 
>               unsigned int new_pos = base == end ? base - 2 : base - 1;____
> 
>     __ __
> 
>         /* Malayalam / Tamil do not have "half" forms or explicit virama
>     forms.____
> 
>          * The glyphs formed by 'half' are Chillus or ligated explicit
>     viramas.____
> 
>          * We want to position matra after them.____
> 
>          */____
> 
>               if (buffer->props.script != HB_SCRIPT_MALAYALAM &&
>     buffer->props.script != HB_SCRIPT_TAMIL)____
> 
>              {____
> 
>                            …____
> 
>               }____
> 
>     __ __
> 
>                            if (start < new_pos && info[new_pos].indic_position
>     () != POS_PRE_M)____
> 
>                            {____
> 
>                                   …____
> 
>                            } else {____
> 
>                                   …____
> 
>                            }____
> 
>             }____
> 
>       }____
> 
>     __ __
> 
>     Please comment, will it have any side effect.____
> 
>     __ __
> 
>     Best Regards,____
> 
>     Uvaraja P.____
> 
>     Sindhura P.
> 
>     ------------------------------------------------------------------------------
> 
>     HarfBuzz mailing list
>     HarfBuzz at lists.freedesktop.org
>     http://lists.freedesktop.org/mailman/listinfo/harfbuzz
> 
> 
> 
> _______________________________________________
> HarfBuzz mailing list
> HarfBuzz at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/harfbuzz
> 

-- 
behdad
http://behdad.org/


More information about the HarfBuzz mailing list