[Fontconfig] WINDOWSTEMPDIR_FONTCONFIG_CACHE

LRN lrn1986 at gmail.com
Fri Apr 12 20:12:51 PDT 2013


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 04.04.2013 02:40, Raimund Steger wrote:
> LRN wrote:
>> What was the rationale behind putting fontconfig cache into
>> temporary directory?
> 
> WINDOWSTEMPDIR_FONTCONFIG_CACHE is only one possible value (aside
> from a real path) for <cachedir> elements on Win32. Current
> fontconfig also supports LOCAL_APPDATA_FONTCONFIG_CACHE; see 
> http://thread.gmane.org/gmane.comp.fonts.fontconfig/3937.
WINDOWSTEMPDIR_FONTCONFIG_CACHE is the default, that's why it caught
my attention.

> 
>> On *nix it resides in /var/cache/fontconfig.
> 
> On Unix, users have cache directories too, as they can use their
> own fonts and/or fontconfig versions.
They can, but as far as Debian goes, dpkg postinst and postrm scripts
only know of one cache - /var/cache/fontconfig, and is set to trigger
cache re-generation when one of these directories
/usr/share/fonts
/usr/share/ghostscript/fonts
/usr/share/texmf/fonts
changes (apparently).
Users can, obviously, whip up anything they like, but that does not
seem to be the "usual" case.

> 
> System-wide fontconfig installations are not really widely used on
>  Windows although a sysadmin could certainly provide such a thing
> (maybe using a custom sysconfdir or fontconfig's feature to load
> its configuration from location relative to the DLL on Windows).
Yes, i'm planning to implement a feature like that. If everything goes
well, expect a patch in foreseeable future.
It will add another special value - RELATIVE_SPECIAL_FONTCONFIG_CACHE,
which will make fc take its location from the DLL, guess where root
directory is (assuming that fc dll is in root/bin), look up
root/var/cache directory, and use root/var/cache/fontconfig as the
cache file.

>> no decent package manager, and i don't think that applications
>> keep track of fonts. Which means that it's important to not to
>> lose fontcache.
> 
> fontconfig updates the cache automatically, applications should not
> need to do anything.

Uh-oh. That is why VLC had loading time of, like, 2 minutes after its
first install. That is, until developers figured out, that they need
to generate fc cache at installation time, from the installer.

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (MingW32)
Comment: Using GnuPG with Thunderbird - http://www.enigmail.net/

iQEcBAEBAgAGBQJRaM0yAAoJEOs4Jb6SI2CwgsEIALlRCK/vGzBD/FrW+bWQ8VDb
HVlC9bsjfYQCfPuWXjlkz4Gj0K6vLPYrJnw5QJ9hyNcX6w3fY84aPgL5ZSX8Qx7G
D49tV/+zZ0+qk/QQok+Y9rEdzVOX2lOsu2TvyPTZjpyxWUaBp0+AV4sVpVeNM2oB
m38KpjsmDkOPrVnC2m0z3cwSThgFMCEICkX9bGT5clYfTHre/7ubKc0V2vg9/5yd
T0ELmvFOQVuxyhvyR8LJcKB2NSH/3ylrP/JcPSGIGIIqSP9tFj2QZ26LDxjjYTsv
Om367W7Bfivvbywa8Mqmec98BlSe3Bq4UAIetdqEFtGXaA3D3eRDpXEybxCJ+e8=
=+Vou
-----END PGP SIGNATURE-----


More information about the Fontconfig mailing list