Bug 398768

Summary: GTK font is being set incorrectly
Product: [Unmaintained] kde-gtk-config Reporter: wsdfhjxc
Component: generalAssignee: Manuel Tortosa <manutortosa>
Status: RESOLVED DUPLICATE    
Severity: normal CC: aleixpol, bugseforuns, kde, nate
Priority: NOR    
Version First Reported In: 5.13.5   
Target Milestone: ---   
Platform: openSUSE   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: The left window is lxappearance, the right window is System Settings

Description wsdfhjxc 2018-09-17 17:04:19 UTC
Created attachment 115044 [details]
The left window is lxappearance, the right window is System Settings

I wanted to set a Roboto Condensed font through GNOME Application Style (GTK) in System Settings. Despite selecting the font from a picker and seeing it being choosen correctly (Roboto Condensed 11), GTK apps are using normal Roboto font, instead of Roboto Condensed.

I can see that ~/.config/gtk-3.0/settings.ini contains:
> gtk-font-name=Roboto Condensed Regular 11

However, if I set Roboto Condensed as a GTK font through lxappearance application, everything seems to be fine and GTK applications kindly use that font.

After that, the settings.ini file contains:
> gtk-font-name=Roboto Condensed, 11

Also, after setting the font correctly through lxappearance, the choosen font is incorrectly displayed in GNOME Application Style (GTK) in System Settings, as Roboto 11 is visible in the Font field, instead of Roboto Condensed 11.
Comment 1 Kai Uwe Broulik 2018-09-18 08:21:08 UTC
It seems the style is correctly applied to GTK2 applications including style (e.g. Italic) whereas GTK3 does not accept the format we give to it.
Comment 2 Kai Uwe Broulik 2018-09-18 08:25:52 UTC
Some settings also just don't work at all. "Courier New Italic" shows as Courier Italic in GTK2, and just Courier in GTK3. Courier New Bold doesn't work at all.
Comment 3 Nate Graham 2018-09-18 20:31:39 UTC
FWIW choosing the Ubuntu font in this KCM works for me in Lollypop, a GTK3 app.
Comment 4 Nate Graham 2019-08-24 13:12:11 UTC

*** This bug has been marked as a duplicate of bug 343561 ***