freetype-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [IDEA] Facilities to extract TT fonts from TTC font collections


From: Werner LEMBERG
Subject: Re: [IDEA] Facilities to extract TT fonts from TTC font collections
Date: Mon, 23 Oct 2023 16:35:18 +0000 (UTC)

> I recently had to extract a TrueType font from a TTC font collection
> as part of fixing bugs in the podofo library[1].

In general, FreeType is not the right tool for such operations.
FreeType is a *rendering* library that provides a thin API for
extracting SFNT tables, mainly the ones FreeType isn't parsing by
itself.  As Behdad mentioned, the `fonttools` package should help you
with your task.

> For example, a special tag TTAG_tdir
> could be defined to access the raw Table Directory data with
> FT_Load_Sfnt_Table, like the following:
> 
> FT_ULong size = 0;
> FT_Load_Sfnt_Table(face, TTAG_tdir, 0, NULL, &size);

Please file a feature request at

  https://gitlab.freedesktop.org/freetype/freetype/-/issues/


     Werner



reply via email to

[Prev in Thread] Current Thread [Next in Thread]