[HarfBuzz] Glyphs with negative advance width

Olivier Berten olivier.berten at gmail.com
Thu Jun 13 23:38:56 PDT 2013


FYI the same happens with this font after khmer character  ុ (glyph
"vowelU") in string ពុម្ព

By the way, it's not only Uniscribe since InDesign and LibreOffice (ICU)
seem to deal the same way with it.

Olivier


2013/6/14 Behdad Esfahbod <behdad at behdad.org>

> Ok, negative vs positive is not the bug.  Uniscribe zeroes mark widths for
> Khmer but we don't.  I tried to figure out whether Uniscribe does it by
> Unicode category or GDEF, but couldn't build a test font...
>
> At any rate, we need to figure out and do the same.  Jonathan, any
> comments?
>
> behdad
>
> On 13-06-13 05:31 PM, Olivier Berten wrote:
> > After khmer character  ិ(glyph "uni17b7") in the string និង
> >
> > Olivier
> >
> >
> > 2013/6/13 Behdad Esfahbod <behdad at behdad.org <mailto:behdad at behdad.org>>
> >
> >     Ok, I'll take a look.  Can you send me the font?
> >
> >     That said, The HarfBuzz API uses signed integers for advance.  So
> I'm not sure
> >     why this is happening.  Where do you observe this behavior again?
> >
> >     b
> >
> >     On 13-06-13 05:16 PM, Olivier Berten wrote:
> >     > Well... Harfbuzz will be the only one behaving that way then...
> >     > That font is rendered fine by Adobe, Microsoft, LibreOffice, ...
> and
> >     fontforge
> >     > as well as ttx/fontTools gives a negative advance width... I guess
> this
> >     > doesn't push fixing the font ;-)
> >     >
> >     > Olivier
> >     >
> >     >
> >     > 2013/6/6 Behdad Esfahbod <behdad at behdad.org <mailto:
> behdad at behdad.org>
> >     <mailto:behdad at behdad.org <mailto:behdad at behdad.org>>>
> >     >
> >     >     Hi Olivier,
> >     >
> >     >     Thanks for the report.  I'm hesitant to make HarfBuzz return
> >     negative advance
> >     >     values as that can confuse downstream users.  If this doesn't
> prove
> >     to be a
> >     >     major issue, I think we should ignore it for now.
> >     >
> >     >     behdad
> >     >
> >     >     On 13-06-01 05:40 PM, Olivier Berten wrote:
> >     >     > Hi!
> >     >     >
> >     >     > Although it isn't complying with the TrueType/OpenType
> specifications,
> >     >     > some fonts have some glyphs with negative advance width.
> >     >     >
> >     >     > Advance width (in htmx) is defined as USHORT/uint16 but it
> seems
> >     >     > everybody else reads it as SHORT/int16.
> >     >     >
> >     >     > In the attached font, glyph "uni17b7" (khmer character  ិ)
> has a
> >     >     > negative advance width. You can try it with the string
> និងសមភាព
> >     >     >
> >     >     > I wouldn't call this a bug in harfbuzz since it's a font bug
> but for
> >     >     > compatibility reasons, it might be useful to change it...
> >     >     >
> >     >     > Olivier
> >     >     >
> >     >     >
> >     >     >
> >     >     > _______________________________________________
> >     >     > HarfBuzz mailing list
> >     >     > HarfBuzz at lists.freedesktop.org
> >     <mailto:HarfBuzz at lists.freedesktop.org>
> >     <mailto:HarfBuzz at lists.freedesktop.org
> >     <mailto:HarfBuzz at lists.freedesktop.org>>
> >     >     > http://lists.freedesktop.org/mailman/listinfo/harfbuzz
> >     >     >
> >     >
> >     >     --
> >     >     behdad
> >     >     http://behdad.org/
> >     >
> >     >
> >
> >     --
> >     behdad
> >     http://behdad.org/
> >
> >
>
> --
> behdad
> http://behdad.org/
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.freedesktop.org/archives/harfbuzz/attachments/20130614/1bef134e/attachment.html>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: Kh-TsKan.ttf
Type: application/x-font-ttf
Size: 170756 bytes
Desc: not available
URL: <http://lists.freedesktop.org/archives/harfbuzz/attachments/20130614/1bef134e/attachment.bin>


More information about the HarfBuzz mailing list