I'm running Linux, and I use Firefox Extended Support Release, 52.6.0, because I depend on certain accessibility/usability extensions which don't work in Firefox Quantum.
I have a small laptop screen with somewhat high resolution, which makes the default Firefox UI font unreadable for me.
I figured out that I can change the UI font size of most applications with an ~/.Xdefaults
setting:
Xft.dpi: 192
This works for things like Gedit and i3, but for some reason Firefox ignores it.
I tried another workaround I found on support.mozilla.org, changing layout.css.devPixelsPerPx
to 1.25 in about:config. On my version of Firefox this changes the size of pretty much everything but the UI text font.
Another suggestion from support.mozilla.org is to use an extension called "Theme and Font Size Changer". However, since the release of Firefox Quantum this extension seems to have been modified to no longer support changing font sizes (it only allows me to change the colors!).
I tried halving my screen resolution with xrandr
(to 640×400), but this breaks many things, for instance various dialog boxes such as print dialogs no longer fit on the screen.
Is there a better solution?
Best Answer
The suggestion to let
layout.css.devPixelsPerPx
control UI font sizes on Linux was rejected.That same bugzilla page recommends to control the UI font sizes with the
GDK_DPI_SCALE
andGDK_SCALE
environment variables.For example, if you're starting Firefox via a launcher shortcut, you can change its command from
firefox %u
toenv GDK_DPI_SCALE=1.25 firefox %u