Linux – How to zoom into the desktop but maintain high resolution for fonts etc

arch linuxawesomewaylandx11

I recently bought a 4K screen (or UHD i.e. 2160p to be exact) and use it on my tower running Arch Linux. As a window manager I use awesome which runs on top of compton for tear-free compositing, as described in this post.

The screen is quite large but still has a higher pixel density than previous screens I used. I would thus like to scale the whole desktop (zoom into it) to have a more comfortable experience (and no longer need to lean towards the screen to read tiny text).

While scaling I still want to take advantage of the high resolution of my screen (e.g. smoother font rendering), thus I do not want to use something like xrandr, which renders the desktop for a smaller resolution and then scales up the rendered raster image.

I tried to find out on which level of my GUI setup (awesome => compton => X) I would need to apply such a configuration, but I have not yet found any useful information. I was also wondering whether this can be achieved under X at all. Apparently, the Wayland compositor Weston supports some kind of zooming in and out the desktop. If it is required, switching to Wayland would certainly be an option too.

In fact I feel that I lake some basic understanding about how the GUI rendering pipeline generally works (starting from the window manager). I would greatly appreciate if someone could point me at some insightful readings.

Best Answer

Hi fellow Awesome WM user! I have had this same issue and found out that Awesome WM currently does not support dpi scaling. So that means we are on our own. A lot of applications pick up the dpi from X server. So make sure your X server has the right dpi (several ways: Xorg conf monitor size, .Xresources, cal xrandr with dpi flag...).

Best solution I found until now: just use a large font-size.
You can also increase the sizes of the menu's and other elements that you find too small.

Wayland is not an option if you want to keep using Awesome WM because it implements the X server api, wayland is something different.

IIRC compton is also not going to help because it doesn't help you with scaling acording to dpi.

Related Question