[HarfBuzz] Mark zeroing mess

Behdad Esfahbod behdad at behdad.org
Thu Feb 11 05:04:42 UTC 2016


Note that, the switch to zeroing by unicode happened, rather unintentionally,
in 568000274c8edb5f41bc4f876ce21fcc8bdaeed8.

Same commit also removed the zeroing of advances of attached marks.  I like to
put that back in, but am testing that with Uniscribe and Devanagari first.

behdad

On 16-02-10 06:11 PM, Behdad Esfahbod wrote:
> I've now confirmed that this is exactly what Uniscribe does for Thai as well.
>  I'm going ahead and making the change.
> 
> On 16-02-10 03:48 PM, Behdad Esfahbod wrote:
>> Hi Jonathan,
>>
>> To my surprise, I have produced evince that, contrary to our previous belief,
>> Uniscribe does NOT zero mark advances in the default (eg. Latin) shaper based
>> on Unicode.  In fact, this is my observation:
>>
>>
>>   - With GDEF:
>>     - If mark is class=3 in GDEF:
>>       -> advance zeroed regardless of whether mark attached in GPOS or not.
>>     - If mark is class != 0 in GDEF:
>>       -> advance NOT zeroed (and mark attachment obviously doesn't apply.)
>>
>>  - No GDEF:
>>    - Mark advance is NOT zeroed; and mark attachment doesn't apply.
>>
>> So, it looks like:
>>
>>   1. Uniscribe is NOT synthesizing any GDEF,
>>
>>   2. It's zeroing mark advance purely based on GDEF.
>>
>> I think our GDEF synthesis is still a good idea.  But like to change advance
>> zeroing to work based on GDEF.  This will fix the following bug:
>>
>>   https://github.com/googlei18n/noto-fonts/issues/472#issuecomment-147528411
>>
>> as well as a bug Martin and I discovered today, which is: currently GC=Mc
>> marks retain their advance, even if they are attached.  That can't be right
>> either...
>>
>> The Thai and Tibetan shapers also use BY_UNICODE_LATE mark-zeroing.  I'm going
>> to test those and change as well, to follow Uniscribe.
>>
>> Comments?  Can you possibly get your monster test suite running after this change?
>>
>> Thanks,
>>
> 

-- 
behdad
http://behdad.org/


More information about the HarfBuzz mailing list