You are not logged in.

#1 2021-11-10 08:50:11

mcloaked
Member
From: Yorkshire, UK
Registered: 2012-02-02
Posts: 1,114

[SOLVED] xorg update broke DPI and font sizes

After updating to xorg-server 21.1.1-2 and related packages, the display on my desktop and laptops are anomalously large and titles on firefox, the fonts on the terminal window and plasma widgets are now all displaying with large and inappropriate sizes.

Exploring it seems that the calculation of the DPI value is broken in the new xorg packages.  On a Lenovo S540 laptop for example the screen/monitor values are shown as:

$ xdpyinfo | grep -B2 resolution
screen #0:
  dimensions:    1920x1080 pixels (344x193 millimeters)
  resolution:    142x142 dots per inch

although the dimensions line is correct, the calculated resolution of 142 dots per inch is wrong. If I manually change it using

xrandr --dpi 96

and start a new terminal window then it displays normally again and correctly.  So presume the new xorg packages have a broken determination of the DPI value?  Aside from downgrading or manually setting the DPI is there another workaround?

As a temporary workaround I have set to force the font dpi to 96 in the plasma desktop by going to system settings, then appearance and in the Fonts section check the 'Force font DPI' and enter 96 and sorted out sddm with:

# cat /etc/sddm.conf.d/dpi.conf
[X11]
ServerArguments=-nolisten tcp -dpi 96

If this is an upstream bug hopefully it will be fixed and pushed to an updated package.  (I found corresponding incorrect DPI values after update on three different machines so this seems to be a sufficiently important issue that it needs to be fixed)

Last edited by mcloaked (2021-11-10 10:43:10)


Mike C

Offline

#2 2021-11-10 09:06:13

V1del
Forum Moderator
Registered: 2012-10-16
Posts: 16,420

Re: [SOLVED] xorg update broke DPI and font sizes

Not a bug and totally expected. Xorg used to unconditionally set 96 which is actually wrong in many  cases. But as people get used to it they assume that's how it must be.

Proof: https://dpi.lv/#15.5%E2%80%B3

If you want to restore the old behaviour explicitly setting it is not a temporary workaround but the actual solution. Otherwise actually go over the rest of the settings and disable manual scalings on the client sizes, reduce fonts to actually correct values etcetc.

See https://bbs.archlinux.org/viewtopic.php?id=271121 and https://bbs.archlinux.org/viewtopic.php?id=271094 and https://www.mail-archive.com/xorg@lists … 06880.html

Last edited by V1del (2021-11-10 09:30:38)

Online

#3 2021-11-10 09:30:45

mcloaked
Member
From: Yorkshire, UK
Registered: 2012-02-02
Posts: 1,114

Re: [SOLVED] xorg update broke DPI and font sizes

Thanks - I just saw the other threads - I guess I needed to understand the new xorg way of doing things! I will mark this as solved as it is a feature and not a bug!

Last edited by mcloaked (2021-11-10 10:42:53)


Mike C

Offline

Board footer

Powered by FluxBB