[HarfBuzz] Request for quick/small Harfbuzz usage flow

Tom Hacohen tom.hacohen at partner.samsung.com
Thu Oct 14 00:45:10 PDT 2010

Thank you very much for your response, more questions below:

On Wed, 2010-10-13 at 12:54 -0400, Behdad Esfahbod wrote:
> I'll put code together soon, but in short: you need a face, a font, and a buffer.
> If using FreeType, it's easy.  Setup your FT_Face (including setting size and
> all), then use hb-ft.h facilities to create face and font.
Sounds like easy fun :)
> Create your buffer and add your text.  You also need to set script, language,
> and direction on the buffer.  The only other piece is a unicode_funcs to set
> on the buffer.  You can get one from hb-glib.h.
First of all: does harfbuzz have a glib dependency? If so, I probably
won't be able to use it (i.e I'll have to "fix" it and send you
patches), if not, good :P

Are there any script/language detecting functions? I know it's not 100%
spot on (even less actually because many languages share many
characters) but that would be a start. Or even better, what's the best
way to detect scripts and languages?
> When all that is done, you are ready to call hb_shape().

Very cool btw, thank you, I'll also have to figure out how to use the
opentype engine for diacritics support.

Thanks a lot,

More information about the HarfBuzz mailing list