You are not logged in.

#1 2023-05-12 15:27:21

Confuze
Member
Registered: 2023-05-12
Posts: 4

[SOLVED] Browsers use monospace font for the ui (tabs, settings etc.)

After updating my system (Arch linux x64) and installing some font packages, (I'm unsure what exactly caused this issue) all of my browsers (chromium, firefox, librewolf) started using the default system monospace font (FreeMono) for all the ui elements. (not the websites, the browser ui elements like the settings, tabs menu etc.)

I'm unsure what's causing this issue since it appears on different browsers and I don't see how my fontconfig could be affecting it.

Here's what I've tried so far:

    Reinstalling all browsers (with cleared pacman cache)
    Uninstalling all the extra downloaded font packages
    Fiddling with the fonts.conf file
    Changing the firefox font settings
    Resetting all the entries containg font in about:config (firefox)

Here's my current fontconfig (~/.config/fontconfig/fonts.conf)

<?xml version="1.0"?>
<!DOCTYPE fontconfig SYSTEM "urn:fontconfig:fonts.dtd">
<fontconfig>
    
  <match target="pattern">
    <test name="family" qual="any">
      <string>serif</string>
    </test>
    <edit binding="strong" mode="prepend" name="family">
      <string>FreeSerif</string>
    </edit>
  </match>

  <match target="pattern">
    <test name="family" qual="any">
      <string>monospace</string>
    </test>
    <edit binding="strong" mode="prepend" name="family">
      <string>FreeMono</string>
    </edit>
  </match>
  
  <match target="pattern">
    <test name="family" qual="any">
      <string>sans-serif</string>
    </test>
    <edit binding="strong" mode="prepend" name="family">
      <string>FreeSans</string>
    </edit>
  </match>
</fontconfig>

And just to make sure that it's actually working here are the results of fc-match

$ fc-match sans-serif
FreeSans.otf: "FreeSans" "Regular"
$ fc-match serif
FreeSerif.otf: "FreeSerif" "Regular"
$ fc-match monospace
FreeMono.otf: "FreeMono" "Regular"

Last edited by Confuze (2023-05-24 15:38:09)

Offline

#2 2023-05-12 16:28:51

Trilby
Inspector Parrot
Registered: 2011-11-29
Posts: 30,491
Website

Re: [SOLVED] Browsers use monospace font for the ui (tabs, settings etc.)

This is most likely related to toolkit settings / styling.  I believe all the browsers you listed use gtk3.  Do you see similar problems with other gtk3 programs (do you have any others?)


"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman

Offline

#3 2023-05-12 18:43:32

Confuze
Member
Registered: 2023-05-12
Posts: 4

Re: [SOLVED] Browsers use monospace font for the ui (tabs, settings etc.)

Welp, this is stupid. I have no clue how I didn't think of this before but yeah, changing the default font in lxappearance absolutely fixes it. Thanks. Super embarassed to have wasted countless hours on this and not come up with such a simple sollution.

Offline

#4 2023-05-13 11:15:07

2ManyDogs
Forum Fellow
Registered: 2012-01-15
Posts: 4,648

Re: [SOLVED] Browsers use monospace font for the ui (tabs, settings etc.)

Please remember to mark your thread [SOLVED] (edit the title of your first post).

Offline

Board footer

Powered by FluxBB