[Fontconfig] Tutorial or guidance for using fontconfig

James Cloos cloos at jhcloos.com
Thu Jan 8 10:29:42 PST 2009

>>>>> "Jesper" == Jesper L Nielsen <jln at locatel.dk> writes:

Jesper> I do have a various number of fonts for different languages and other
Jesper> things, so the first performance hit is when fontconfig builds it's
Jesper> cache on startup, if there is a way to disable this, I haven't found it.

Ideally, the cache should be built as part of generating the firmware
image, not at runtime.

If the user can add fonts, they should go into a directory just for such
fonts (much like a workstation user's ~/.fonts directory).  Only adding
or removing fonts from that dir would cause new caching, and only of
fonts in that dir.

If the user cannot add or remove fonts, then the cache can be in "rom".

The easy way to generate the cache would be to use real hardware or a
simulator, but fc's src is easy enough to read that modifying it to
write an app which runs on one platform and creates cache files for a
target platform should be straight forward.  That would allow you to
create the cache files as part of your normal firmware build process.

You don't need to disable the cache, you need to generate it once, ahead
of time, and let your product use it.

James Cloos <cloos at jhcloos.com>         OpenPGP: 1024D/ED7DAEA6

More information about the Fontconfig mailing list