The answer to question #1 is yes. That approach would have to be supported at the application level.
The answer to question #2 is also yes. You can generate fontconfig configuration files that limit what the system sees before you run the application, or even while it's running in most cases, though that wouldn't be application specific but desktop wide.
As far as the specification goes, doing your own if/then/else doesn't sound like the best idea, sounds rather messy. You should probably just use the functions provided by glib, unless you really want to avoid depending on it for whatever reason.
On Sep 11, 2017 5:13 AM, "Donn Ingle" <donn.ingle@xxxxxxxxx> wrote:
> Date: Sun, 10 Sep 2017 20:45:08 +1200
> From: Lawrence D'Oliveiro <ldo@xxxxxxxxxxxxxxxxxxx>
> To: fontconfig@lists.freedesktop.org
> Subject: Re: Two questions for too many fonts and
> Fontypython
> Message-ID: <20170910204508.7ce7a9fd@theon.geek-central.gen.nz >
> Content-Type: text/plain; charset=US-ASCII
>
> On Sun, 10 Sep 2017 10:26:05 +0200, Donn Ingle wrote:
>
> > I don't suppose this is a fontconfig problem, per se, but more one
> > for the gui people in GTK-etc-land.
> Apps can certainly use Fontconfig to help with this, by creating
> user-controlled configuration objects that only include fonts from
> specified paths.
I'd like to know more about this process.
1. Does it have to be each individual app developer who volunteers to do this? i.e. is it baked-into the code?
2. Can it be a general script/app that pre-manages fonts according to what software you are about to run?
(For e.g. I know I'm gonna be designing, so Gimp/Inkscape/Scribus are in my near future. I can wave my wand and say "Font-o-noisia-vanescere!" and — Poof! — a sane environment. I can then use whatever font manager to prepare specific fonts I want installed and start working.
It's not that I want to micro-manage fonts per application really. That would suck. I simply want a quieter, shorter list of them for certain kinds of work.)
> ~/.fonts is deprecated (do your bit to help reduce dotfile clutter!),
> you should use ~/.local/share/fonts instead.
I will begin to alter my assumptions in code right away. Is this correct?
https://specifications.freedesktop.org/basedir-spec/ basedir-spec-latest.html
There's a fairly tricksy cascade of if/thens in the "Environment variables" section concerning $XDG_* variables. Is that the recipe I should follow?
Thanks,
/d
_______________________________________________
Fontconfig mailing list
Fontconfig@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/fontconfig
_______________________________________________ Fontconfig mailing list Fontconfig@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/fontconfig