You are not logged in.

#1 2015-05-24 23:09:08

i542
Member
Registered: 2015-05-24
Posts: 3

[Solved] Cinnamon: How to change default font for Gtk2 apps?

So, I've decided to try out KDE/Plasma a few weeks ago. I disliked it, uninstalled plasma-desktop and all of its dependencies. Since that event, all Gtk2 windows use a weird monospace font. Example (background: Chromium, foreground: Nautilus)

kbrgoc.png

Things I've tried:

* Googling and searching on the forums.
* Using qtconfig-qt4 to change the default font from Andale Mono to something more sensible like Droid Sans. (Weirdly enough, the choice reverts to Andale Mono even though I save the changes)
* Reinstalling KDE/Plasma and changing the font settings there.
* Removing ~/.config/Trolltech.conf

I'd be appreciative if someone has a solution to this problem.

Cheers!

Edit: Looks like the problem was in GTK2, not Qt5 like I originally assumed. I apologize for the confusion. There's a solution lower in this thread. I've edited the post with correct terms so that people can find it in the future.

Last edited by i542 (2015-05-27 21:16:02)

Offline

#2 2015-05-25 09:24:57

Chazza
Wiki Maintainer
Registered: 2013-06-02
Posts: 506

Re: [Solved] Cinnamon: How to change default font for Gtk2 apps?

Does the following application help at all? Link: http://qt-apps.org/content/show.php/Qt5 … ent=168066

Offline

#3 2015-05-25 21:51:39

cedeel
Member
From: ~
Registered: 2009-08-25
Posts: 176
Website

Re: [Solved] Cinnamon: How to change default font for Gtk2 apps?

Eh, Chromium isn't a Qt application.

Offline

#4 2015-05-26 01:33:33

i542
Member
Registered: 2015-05-24
Posts: 3

Re: [Solved] Cinnamon: How to change default font for Gtk2 apps?

Chazza wrote:

Does the following application help at all? Link: http://qt-apps.org/content/show.php/Qt5 … ent=168066

Yes, unfortunately this did not fix the problem. I did put the environmental variable in .profile and relogged, the result was unfortunately the same. I've managed to fix fonts in Clementine using qtconfig-qt4 after some fiddling, but applications like Docky and Chromium still have the monospace font.

cedeel wrote:

Eh, Chromium isn't a Qt application.

Ah, my bad. Do you know of a way to fix that problem anyway?

Offline

#5 2015-05-26 09:03:26

Chazza
Wiki Maintainer
Registered: 2013-06-02
Posts: 506

Re: [Solved] Cinnamon: How to change default font for Gtk2 apps?

Ah, I think I see the problem. Your Qt4 applications are fine as you said, your GTK+ 3 applications are fine (looking at your Nautilus screenshot, they seem to be) so the problem lies with GTK+ 2 applications (Chromium depends on the gtk2 package).

Check your hidden files in your home directory. Do you have a .gtkrc-2.0 file by any chance? Font settings there would override the defaults set elsewhere.

Offline

#6 2015-05-26 14:05:43

cris9288
Member
Registered: 2013-01-07
Posts: 348

Re: [Solved] Cinnamon: How to change default font for Gtk2 apps?

You need to set the theme for gtk2 apps. You can use lxappearance for this.

Offline

#7 2015-05-26 14:29:30

Chazza
Wiki Maintainer
Registered: 2013-06-02
Posts: 506

Re: [Solved] Cinnamon: How to change default font for Gtk2 apps?

cris9288 wrote:

You need to set the theme for gtk2 apps. You can use lxappearance for this.

The OP's issue is with the font, not the theme. LXAppearance will indeed write to .gtkrc-2.0. However, the OP mentions Cinnamon in the title. I would assume that the OP actually wants to set theme settings and font settings in Cinnamon itself. If that is the case, and a gtkrc-2.0 file is what is causing the strange fonts, then the better solution would be to remove the .gtkrc-2.0 file and just let Cinnamon handle those settings.

Offline

#8 2015-05-27 21:14:37

i542
Member
Registered: 2015-05-24
Posts: 3

Re: [Solved] Cinnamon: How to change default font for Gtk2 apps?

Chazza wrote:

Ah, I think I see the problem. Your Qt4 applications are fine as you said, your GTK+ 3 applications are fine (looking at your Nautilus screenshot, they seem to be) so the problem lies with GTK+ 2 applications (Chromium depends on the gtk2 package).

Check your hidden files in your home directory. Do you have a .gtkrc-2.0 file by any chance? Font settings there would override the defaults set elsewhere.

Well, butter my butt and call me a biscuit, that was indeed the problem:

avdxox.png

Thank you! I'll edit the title so that it makes more sense.

Offline

Board footer

Powered by FluxBB