You are not logged in.
Pages: 1
I am looking for the location that defines the default font in Firefox. By default font I mean that one that is inside the selection, like the one that defines Bitstream Vera Sans in this image:
http://i64.tinypic.com/f4r5hu.jpg
It seems to affect more applications, so I think it is actually a GTK thing, but I don't know how to change it. The global GTK configuration files, settings.ini and gtkrc (which shouldn't be used, as it is for GTK 2), have Cantarell as gtk-font-name. I don't have local files.
I am using XFCE. Do I have to install GNOME to solve the problem?
Assuming that it's a GTK thing, that is.
Last edited by go4linux (2018-07-06 14:47:29)
Offline
You change it by selecting another (installed) font in the drop down: what is tricky about that? The Default assignation is determined by your fontconfig.
Also, read the Code and only p[ost thumbnails: http://wiki.archlinux.org/index.php/Cod … s_and_code
Offline
Assuming that you're after more than just how to set this in firefox, have a look at Font Configuration in the wiki for where and how the default font aliases are set. Plus some examples.
N.B installing fonts-meta-base from AUR pulls in a lot of useful fonts and provides an aliases file that's easy to edit to your liking.
Offline
You change it by selecting another (installed) font in the drop down: what is tricky about that?
That it doesn't work. Not always at least. For example, for the archlinux.org page, I have to click on Advanced and change the settings for Latin, specifically for the sans-serif font. The advanced settings all point to the Default fonts.
Also, as I said that seems to affect other applications. I am saying this because I couldn't get rid of a monospace font appearing everywhere, until I installed more fonts.
Also, read the Code and only p[ost thumbnails: http://wiki.archlinux.org/index.php/Cod … s_and_code
I did. The image was 13.6 kB, so that wasn't a problem. I wasn't sure about the size, since the image was 791x172. So I decided to go the easy way: check the preview, assuming I would be notified if the image was too big. I guess I was wrong.
Next time I will post a link. Looks easier
Assuming that you're after more than just how to set this in firefox, have a look at Font Configuration in the wiki for where and how the default font aliases are set. Plus some examples.
Thank you. I did look at it, just maybe too quickly. However, I am not sure it is what I need.
If I understand correctly, the idea would be to replace the Bitstream Vera fonts with some fonts I would like to use. If that is correct, I think that also means that it won't be possible to use the Bitstream Vera fonts, as they will always be replaced. Is that right?
N.B installing fonts-meta-base from AUR pulls in a lot of useful fonts and provides an aliases file that's easy to edit to your liking.
Ah, thanks. I will look at it when I will look at the AUR :-D
I am not there yet.
It really looks like something happens when I install a font, just I don't know what.
Last edited by go4linux (2018-07-06 06:42:35)
Offline
radiomike wrote:Assuming that you're after more than just how to set this in firefox, have a look at Font Configuration in the wiki for where and how the default font aliases are set. Plus some examples.
Thank you. I did look at it, just maybe too quickly. However, I am not sure it is what I need.
If I understand correctly, the idea would be to replace the Bitstream Vera fonts with some fonts I would like to use. If that is correct, I think that also means that it won't be possible to use the Bitstream Vera fonts, as they will always be replaced. Is that right?
You don't replace the fonts, just change the fontconfig rules that give bitstream Vera as the result when you use an alias like "sans" or "sans serif" to select the font. Bitstream Vera fonts will still be accessible directly.
It really looks like something happens when I install a font, just I don't know what.
Either your font is adding new rules to fontconfig which will change the defaults, or it ends up as a preferred option based on the existing rules.
Offline
Either your font is adding new rules to fontconfig which will change the defaults, or it ends up as a preferred option based on the existing rules.
Yes, that was it. The file /etc/fonts/conf.avail/60-latin.conf had something like:
<alias>
<family>sans-serif</family>
<prefer>
<family>Bitstream Vera Sans</family>
<family>DejaVu Sans</family>
<family>Verdana</family>
<family>Arial</family>
<family>Albany AMT</family>
<family>Luxi Sans</family>
<family>Nimbus Sans L</family>
<family>Nimbus Sans</family>
<family>Helvetica</family>
<family>Lucida Sans Unicode</family>
<family>BPG Glaho International</family> <!-- lat,cyr,arab,geor -->
<family>Tahoma</family> <!-- lat,cyr,greek,heb,arab,thai -->
</prefer>
</alias>I just added a family at the top, before the Bitstream Vera Sans:
<family>Noto Sans</family>It's still unclear why now Firefox takes Noto as global default if I specify it only in the Latin configuration, but at least it works.
Many thanks
Offline
Yes, that was it. The file /etc/fonts/conf.avail/60-latin.conf had something like:
That file will be overwritten on package update.
It's still unclear why now Firefox takes Noto as global default if I specify it only in the Latin configuration, but at least it works.
Many thanks
It is the default for content detected as being in Latin based languages if that is the only type of language you view in firefox it would become effectively a global default.
Offline
That file will be overwritten on package update.
crap, I should have known that. Thanks for that.
So, now I have the problem of setting the right order. If I want to do that globally, how do I do that? Doing that in local.conf doesn't seem to work. Adding a file 99-local.conf doesn't work either.
Coming to think of it, how does 60-latin.conf know that it's for Latin? There is no mention of it in the file.
The man page doesn't help a lot. Some more knowledgeable advice might help.
It is the default for content detected as being in Latin based languages if that is the only type of language you view in firefox it would become effectively a global default.
Maybe I misunderstand your answer, but it appears as generic default font in the preferences. It's not content related.
Offline
Font_configuration#Fontconfig_configuration I would suggest using $XDG_CONFIG_HOME/fontconfig/fonts.conf or 99-local.conf which you already tried.
With the content from Font_configuration#Replace_or_set_default_fonts setting the default sans-serif to Noto Sans etc.
Offline
Okay, so I copied my 99-local.conf into $XDG_CONFIG_HOME/fontconfig/fonts.conf and that worked. Very odd.
Then I noticed that local configuration is loaded from the 50-user.conf file. So I tried two things:
1) copying my 99-local.conf into /etc/fonts/conf.d/60-local.conf. That didn't work
2) copying my 99-local.conf into /etc/fonts/conf.d/60-before-latin.conf. That worked.
Recall that the original font preferences are set in the 60-latin.conf file.
So it seems that it's a configuration loading order problem. The files that are read first set the values, and they are not overwritten by the files that are read later, as I would expect.
Maybe they could add it to the fontconfig documentation. That would help.
So, hopefully now I'm done with this problem. Thanks for the help.
Offline
Pages: 1