Terminus font name fix after freetype2 update to 2.7.1-1

font

#1

After recent upadate Terminus font name changed to ‘xos4 Terminus’. It was intended by freetype2 developers, but it is a bit inconvenient to change user config files in order to use the new font name. I suggest using fontconfig alias feature to “fix” it.
Create a file /etc/fonts/conf.avail/33-TerminusPcfFont.conf (or any other name) with following content:

<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "fonts.dtd">
<fontconfig>
<!-- Fix the name of Terminus font -->
  <alias>
    <family>Terminus</family>
    <prefer><family>xos4 Terminus</family></prefer>
    <default><family>fixed</family></default>
  </alias>
</fontconfig>

Then create a link to it in /etc/fonts/conf.d:
sudo ln -s /etc/fonts/conf.avail/33-TerminusPcfFont.conf /etc/fonts/conf.d
If you don’t want to make a system-wide change just place the file to ~/.config/fontconfig/conf.d
Now it shoud work again under ‘Terminus’ name. You may need to relogin if you use Terminus in .Xresources.


Terminus font missing in XFCE Edition (17.0-beta3)
[Stable Update] 2017-01-17 - Python, Xorg, Ruby, Gcc, Inkscape
[Testing Update] 2017-01-11 - Python3.6, Mesa, Breath-themes, Kernels, Xorg 1.19
#2

Thanks!
Can you put that config file in /etc/fonts/conf.avail and symlink it to conf.d as with other fontconfig files? It should be implemented system-wide IMHO.


#3

This method has a disadvantage though. It only substitutes “xos4 Terminus” for “Terminus”, but font lists still have only “xos4 Terminus”. I think some additional config is needed.


#4

Maybe. Have to try that.

EDIT. Yes, it works the same. I’ve edited original post to use /etc/fonts/


#5

Thanks! The name change broke a whole lot of stuff in bspwm edition. Also, dmenu does not seem to accept font names with spaces when passed through a variable, so this might also remedy that.


#6

Worked on a freshly installed (with the new CLI installer) bspwm. Terminus font package wasn’t installed first, but after installing and adjusting fonts conf like you posted everything shows the right font even if all GUI font settings show None as selected.


#7

Is it just a cosmetic issue then, after adjusting the config file?


#8

I cannot generalize it…


#9

This fixes the dmenu issue. I would put it on the next bspwm edition if there was no threat they change it back soon…


#10

This solution just creates an alias for “Terminus” font so that if system can not find the font it substitutes “xos4 Terminus”. But if after some future update the font name will return to normal “Terminus” it will just work without problems, because the system will find the font as usual without substitution.


#11

Aah. I thought it would substitute it with ‘xos4 Terminus’ even then. Definitely in the next edition then!


#12

It might be helpfull even to create generic font aliases (like serif, sans and mono) to make theme changing easier. For example, it is possible to use alias, say, “defaultfont” or “bspwmfont” and keep all config files with that alias. Then you can edit just one fontconfig file to change all fonts at once.


#13

Will this fix be included in the next stable update, or is manual user intervention required? Not a problem for me, but maybe for others.


#14

It is an annoying issue, but not a critical one. Even an inexperienced user would search the options for fonts in a application’s window if the font breaks.
If there is manpower and an idea for a generalized solution, we might expect this to happen.


#15

Yeah, not everyone uses Terminus anyway, at least on official ISOs. Let’s just see how this evolves.
For terminal-heavy editions like i3, it would be nice to have though.


#16

I’d like to make this into a generalized solution. Mostly it is not very critical for gui elements, but that breaking of dmenu settings is hard for average user to fix.


#17

Perhaps we could just package this as a separate package? It would be easy to do and easy to slap in any edition that needs it.

Like this: https://github.com/Chrysostomus/terminusfix/tree/master


#18

It would be nice.


#19

After the update, and despite the fix, my terminus font looks extremely streched in urxvt.
Any idea where that comes from?


#20

It looks like some Dejavu Sans, not Terminus. Check what fc-match Terminus gives you.