Sample Header Ad - 728x90

Force Firefoxe's chrome change font size when DPI changes

2 votes
0 answers
272 views
I sometimes need to switch between displays of vastly different DPIs. For that, I change the X database using xfconf, a part of Xfce, like so:
xfconf-query -c xsettings -p /Xft/DPI -s 144  # or 96, etc.
All applications I run, both GTK2, GTK3, and Qt, react correctly to that, and change their dimensions. Firefox (all the versions up to 71) ignores the DPI change completely: address bar, menus, etc remain the same size pixel size until I restart the browser. After a restart, the current DPI is honored. Changing layout.css.devPixelsPerPx does affect page content scaling, but not the UI font scaling. Setting it to -1 or positive values does not make Firefox react to the DPI change. Is there any way to make Firefox change these font sizes dynamically? I'd be OK to do it even manually, just without a restart. Some about:config flags, user chrome overrides, etc? I run Void Linux and the Firefox packaged with it.
Asked by 9000 (1681 rep)
Dec 26, 2019, 06:17 PM
Last activity: Dec 26, 2019, 06:33 PM