FS#73069 - [gsfonts] messes with default fonts, making 3rd-party apps look ugly

Attached to Project: Arch Linux
Opened by ratijas (ratijas) - Friday, 17 December 2021, 21:22 GMT
Last edited by David Runge (dvzrv) - Saturday, 19 February 2022, 12:59 GMT
Task Type Bug Report
Category Packages: Extra
Status Closed
Assigned To David Runge (dvzrv)
Architecture All
Severity Medium
Priority Normal
Reported Version
Due in Version Undecided
Due Date Undecided
Percent Complete 100%
Votes 0
Private No

Details

Description:

Merely installing gsfonts package messes up with Sublime Text/Merge so bad, it almost becomes an eye-bleeding experience.

I don't know much about fontconfig, but I know that on my system without gsfonts:

- KDE's Fonts KCM (system settings) are set to "Noto Sans", and
- fc-match prints:

```
$ fc-match system
NotoSans-Regular.ttf: "Noto Sans" "Regular"
```

But after installing gsfonts:

```
$ fc-match system
NimbusSans-Regular.otf: "Nimbus Sans" "Regular"
```

Nimbus and Noto Sans screenshots of Sublime Merge:

- Nimbus: https://cdn.discordapp.com/attachments/280157083356233728/921436423268204584/Sublime_Merge_text_labels_are_1px_high.png
- Noto Sans: https://cdn.discordapp.com/attachments/280157083356233728/921459554099818516/unknown.png

The worst thing is, a user don't even need to know about this font or this package. I just installed Rizin/Cutter, suspecting absolutely nothing; and after reboot I was surprised by such sudden inconvenience. Since I'm living on the edge of KDE, I wasn't even suspecting Cutter/gsfonts for a week, hoping that it will sort itself out -- just like many temporary bugs on master branch.

I believe it is unacceptable that simply instally a pack of fonts may mess up with user's system in such way. Again, I'm not an expert in font packaging, but the current approach clearly creates very strange and hard-to-debug problems for users.

Additional info:
* package version(s):
- gsfonts: 20200910-2
* config and/or log files etc.:
- No user config on my system. The problem is reproducible in a clean environment, with a freshly created user account.
* link to upstream bug report, if any: None

Steps to reproduce:

1. Run `$ fc-match system` to ensure that default fonts are still the ones you like.
2. Install gsfonts or anything that eventualy hard-depends on it, e.g. rz-cutter in my case.
3. Run `$ fc-match system` again to ensure you defaults are already messed up.
2. Restart Sublime Merge to see the horrible font taking over: all labels are 1-2px higher than they should be, which often makes them look mis-aligned w.r.t. to their icons or background highlight rectangle.
This task depends upon

Closed by  David Runge (dvzrv)
Saturday, 19 February 2022, 12:59 GMT
Reason for closing:  Not a bug
Additional comments about closing:  Please bring this up with sublime's upstream. This is neither a bug in fontconfig nor in gsfonts.
Comment by Antonio Rojas (arojas) - Friday, 17 December 2021, 22:17 GMT
KDE fonts KCM only affects Qt and GTK applications and is unrelated to fontconfig's defaults. If you want to configure a default font for non-Qt and non-GTK applications you have to do it via a fontconfig conf file, otherwise it will just pick up the first match, which depends on which fonts you have installed. So this is expected.
Comment by ratijas (ratijas) - Friday, 17 December 2021, 22:33 GMT
Welll... I know Arch is supposed to be for advanced users who know every single screw in their system. But I think even advanced users have better things to do other than keeping an eye on all and every transitive dependency that might override some system stuff with their shitty defaults.

I've been living on Arch for ~five years, and I didn't know this could be a problem until now... which goes to say that

1. I'm a bad admin of my own machine, and probably unworthy of Arch Linux (btw);
2. It was perfectly fine to live for five years straight without getting into this mess, so sane defaults are a thing.

Most importantly: installing a font pack != (or least should not be *possible* to be equal to) changing system-wide default fonts. Is there a possible fix to this situation in any reasonable way?

Font config looks pretty scary and complicated. I don't think KCM would ever support it, right?

Loading...