Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 475488 - font.eclass add non-standard Xorg FontPath elements (WAS: media-fonts/termsyn should install a fontconfig file)
Summary: font.eclass add non-standard Xorg FontPath elements (WAS: media-fonts/termsyn...
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Eclasses (show other bugs)
Hardware: All Linux
: Normal normal with 1 vote (vote)
Assignee: Gentoo Fonts Team
Keywords: PATCH
Depends on:
Reported: 2013-07-02 11:42 UTC by Ondrej Grover
Modified: 2021-07-27 05:02 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---

/etc/X11/xorg.conf.d/99-termsyn-font.conf (10-fonts.conf,68 bytes, text/plain)
2013-07-02 11:44 UTC, Ondrej Grover
bad hack in user .xinitrc (file_475488.txt,353 bytes, text/plain)
2013-07-03 10:37 UTC, Michael Weber (RETIRED)
font.eclass patch (font.eclass.patch,2.48 KB, patch)
2013-07-03 11:57 UTC, Michael Weber (RETIRED)
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ondrej Grover 2013-07-02 11:42:15 UTC
the termsyn font is installed into /usr/share/fonts/termsyn/
which is not a default font directory for X

This results in applications not using fontconfig like xfontsel, dzen2 to not know of this font.

This can be easily fixed by 
xset fp+ /usr/share/fonts/termsyn/
xset fp rehash

or more conveniently by making a file /etc/X11/xorg.conf.d/99-termsyn-font.conf
Section "Files"
    FontPath "/usr/share/fonts/termsyn/"

I suggest such a file should be added for each font in a non-default directory.
Possibly this could be an eclass function.

Re-logging in will not help.

Reproducible: Always
Comment 1 Ondrej Grover 2013-07-02 11:44:04 UTC
Created attachment 352442 [details]
Comment 2 Michael Weber (RETIRED) gentoo-dev 2013-07-03 10:21:09 UTC
Hello fonts team,

I've identified following packages exhibiting the same situation
(These are just the fonts installed on my laptop, and it's non exhausive)


What do you think about it?
I don't know what the fancy X11 window managers do about it, but I think this has to be addressed on a X11 server level. Esp. for users w/o any window manager or simple ones, these should not be forced to fix fp path in their user profile. My x11-base/xorg-server-1.14.2 (latest ~amd64) has these paths included by compilation

[    56.547] (WW) The directory "/usr/share/fonts/TTF/" does not exist.
[    56.547]    Entry deleted from font path.
[    56.547] (WW) The directory "/usr/share/fonts/OTF/" does not exist.
[    56.547]    Entry deleted from font path.
[    56.547] (WW) The directory "/usr/share/fonts/Type1/" does not exist.
[    56.547]    Entry deleted from font path.
[    56.551] (==) FontPath set to:
Comment 3 Michael Weber (RETIRED) gentoo-dev 2013-07-03 10:37:15 UTC
Created attachment 352506 [details]
bad hack in user .xinitrc
Comment 4 Michael Weber (RETIRED) gentoo-dev 2013-07-03 11:57:02 UTC
Created attachment 352512 [details, diff]
font.eclass patch

Add /etc/X11/xorg.conf.d/90-${FONT_PN}-${SLOT}.conf file and
inform the admin about changes in the fontpath elements.
Comment 5 Ben de Groot (RETIRED) gentoo-dev 2013-07-03 14:21:36 UTC
No objections from me
Comment 6 Ondrej Grover 2013-07-03 14:29:29 UTC
Wow, thank you very much for this quick reaction. I'm glad it was recognized and that my eclass proposition was heard out.
I believe this fix will benefit many users, especially the inexperienced ones that wonder why their fonts aren't showing up.

As a for WMs taking care of this, IMHO it's not what a WM is supposed to do, so I don't think it should be relied upon the WM to make the fonts accessible. 

I just hope that a bunch of /etc/X11/xorg.conf.d/90-${FONT_PN}-${SLOT}.conf files won't slow down X server initialization. Could anybody with lots of files in /etc/X11/xorg.conf.d/ share their experience?
Comment 7 Michael Weber (RETIRED) gentoo-dev 2013-07-06 11:57:19 UTC
There is/was a discussion about this on gentoo-dev-ml
Comment 8 Ben de Groot (RETIRED) gentoo-dev 2013-08-21 08:29:47 UTC
(In reply to Michael Weber from comment #7)
> There is/was a discussion about this on gentoo-dev-ml

How do you think we should proceed now?
Comment 9 Dimitrios Semitsoglou-Tsiapos 2015-04-26 12:03:30 UTC
Have any decisions been taken about this issue since?
Comment 10 Ben de Groot (RETIRED) gentoo-dev 2015-05-07 09:14:56 UTC
Michael, do you still want to pursue this?

I for one don't think it is necessary, as most software uses fontconfig these days. If you're using something more ancient, then it is easy enough to configure manually. 

But we're not against an opt-in solution, not enabled by default, to not slow down X startup unnecessarily for the majority of users who don't need this.