[HarfBuzz] How to get hb_face_t and hb_font_t without Freetype?

Behdad Esfahbod behdad at behdad.org
Sat May 11 18:38:58 UTC 2019


On Sat, May 11, 2019 at 11:36 AM Eli Zaretskii <eliz at gnu.org> wrote:

> > From: Behdad Esfahbod <behdad at behdad.org>
> > Date: Sat, 11 May 2019 11:26:29 -0700
> > Cc: Jonathan Kew <jfkthame at gmail.com>,
> >       "harfbuzz at lists.freedesktop.org" <harfbuzz at lists.freedesktop.org>
> >
> > Or just use hb_face_create() and hb_font_create().
>
> Thanks, that's what I thought I needed to do to begin with.  However,
> hb_face_create needs a 'blob' argument, and I couldn't understand how
> to call hb_blob_create to get a suitable blob.  Then I looked at how
> hb_ft_face_create does it, and saw that it makes a blob out of FT_Face
> structure.  But I couldn't see how that blob is used by HarfBuzz, and
> so couldn't decide how to call hb_blob_create in my case.
>

The blob simply hold the font file bytes.  There's even
hb_blob_create_from_file.

Makes sense?

-- 
behdad
http://behdad.org/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/harfbuzz/attachments/20190511/4f7b10b8/attachment.html>


More information about the HarfBuzz mailing list