[HarfBuzz] What is the utility of the advances list?

Khaled Hosny khaledhosny at eglug.org
Tue Oct 29 04:01:51 PDT 2013


On Tue, Oct 29, 2013 at 11:49:02AM +0100, eduardo wrote:
> Is there any reason other than the kerning? Bacause it can be extracted
> quite easily using the FT_Get_Kerning function.

Kerning is just an example, other GPOS features can change glyph
advances (or even HarfBuzz itself, e.g. when zeroing the advance width
of combining marks), and even kerning can't just be extracted from
FT_Get_Kerning() since it only covers the old 'kern' table (which
HarfBuzz will only use as fallback) not GPOS kerning.

Regards,
Khaled

> On Tue, 29 Oct 2013 10:40:59 +0000, Jonathan Kew wrote:
> >On 29/10/13 10:19, eduardo wrote:
> >>Hi,
> >>
> >>Why does hb return a list of advances when, given a glyph, it can easily
> >>be extracted from the font? Are the glyph advances context dependant? If
> >>so, what is a good language/script to see the difference?
> >>
> >
> >Yes, of course they're context-dependent. The simplest example may be
> >kerning. If the GPOS table contains a kern pair for "AV", then the
> >advances you get from harfbuzz for the 'A' and 'V' glyphs will not be
> >the same as the individual glyph advances you'd find in the font.
> >
> >_______________________________________________
> >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



More information about the HarfBuzz mailing list