I have a nice new shiny 4k monitor. I can increase the font size for most applications (including awesome) however, there are a few issues:

  1. The wibar vicious widgets show a tiny font, not the one defined in theme.lia.
  2. Any Gnome applications still show the old (aka tiny) font size.

I suspect that setting the font size everywhere will lead me going insane. Is there a DPI setting within Awesome I can use?

If not, is there some xrandr magic I can do?

  • AFAIK xrandr can only do some scaling, but then you wouldn't need the 4k monitor. But you could keep it in mind in case you want to connect a lower dpi screen as well. Commented Nov 16, 2016 at 21:29
  • @JakobLenfers Login in using Gnome does some scaling so there is the ability in there to do it. How it does it, that's the question. Commented Nov 17, 2016 at 8:15
  • 1
    Maybe you'll find something useful here: wiki.archlinux.org/index.php/HiDPI Commented Nov 17, 2016 at 13:48
  • 1
    @JakobLenfers That's currently the best I have… Commented Nov 17, 2016 at 15:29

3 Answers 3


With awesome 4.0 on Debian stretch, no patch as in the answer of Sardathrion is needed, that is to change your dpi to get a proper screen setup, you need to

1) Create the .Xresources file with your settings, that is Xft.dpi: 192 If you are wondering about the right DPI value, see this post. I used the next value that was a multiple of 96.

For more interesting settings, check out the informative Arch wiki entry

2) I needed to include the settings from .Xresources by adding the following line to the file .xinitrc xrdb -merge ~/.Xresources

  • Thanks for this great answer. Could you please tell me where the magic number 96 comes from?
    – select
    Commented Nov 6, 2019 at 19:13
  • Worked for me too.
    – SdSaati
    Commented Jun 11, 2020 at 8:25

An inelegant hack!

Currently, I am using a mix of

xrandr --output HDMI-1 --scale 0.8x0.8
export GDK_SCALE=2
export GDK_DPI_SCALE=0.6

And setting fonts. Mostly, it was taken from Arch Linux's section on HiDPI.

Not elegant at all ☹

A real solution…


Issue 760 suggests that the current master branch of awesome does support custom DPI. And issue 1225 is my attempt at doing things properly.

Install master branch

sudo dnf uninstall awesome #  ← This might unisntall dependencies, re-install those!
sudo dnf install -y xorg-x11-server-Xephyr
cd ~/src/awesome # Or where ever the source is.
rm -r .build*

You now need to apply this patch, once that'd done resume:

make CMAKE_ARGS="-DCMAKE_INSTALL_PREFIX:PATH=/usr -DAWESOME_DOC_PATH=/usr/share/doc/awesome -DSYSCONFDIR=/etc " all package
sudo rpm --vv --install build/awesome*rpm
Xephyr :1 &
DISPLAY=:1 awesome -c /etc/xdg/awesome/rc.lua

If the above works, you should be nearly there. If not, use dnf to install awesome.

Nearly done, just some book keeping left.

You old configuration will not longer work, so you need to get the files from the xresources theme as well as the default rc.lua file. I would strongly recommend you take a backup of the old configuration, but really what could go wrong⸮

Your ~/.Xresources could look like this:

Xft.dpi:        156
Xft.antialias:  true
Xft.hinting:    true
Xft.rgba:       rgb
Xft.hintstyle:  hintslight

Make sure you disable awesome from being updated via dnf by adding exclude=awesome to /etc/dnf/dnf.conf.

Finally, log out (reboot, whatever) and log back in: you should now be ready.

  • If y is omitted from scale, the x is used for both, simplifying the first line of you hack to: xrandr --output HDMI-1 --scale 0.8.
    – mcp
    Commented Mar 15, 2022 at 20:30

On my Laptop with 3200x1800px I can set the scaling to 0.5 which displays everything correctly with:

xrandr --output $(xrandr|head -n2|tail -n1|cut -d\  -f 1) --scale 0.5x0.5

But the drawback is, that this renders the text really blurry

A solution with a sharper display is setting the resolution of the screen to half size with

xrandr -s 1600x900

This works quite well for some applications, for example Firefox looks perfect, but for example chrome has a big problem with that solution and displays all gui-menues in a really tiny font. A workaround for this I found by starting chromium on the console with

chromium-browser --force-device-scale-factor=1.0

So it seems you have to adapt many applications by hand this way.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .