There are a number of solutions in various forums and Stack Exchange using scaling (e.g. --scale 2x2
or --scale-from 1920x1440
).
While these did work for me, there was a slight blurriness on the up-scaled monitor. It was not very obvious and could be missed easily, but I am very sensitive to such things and it gave me headaches.
A better solution which does not create any blurriness is to use --transform
instead of --scale
.
The position of the 2 monitors needs to be set properly: the likes of --left-of
, --below
, etc. don't work as they don't take into account the transformation.
Here is what I am using, with explanations of each value so that you can adapt it to your situation:
xrandr --output DP-1 --mode 2560x1440 --pos 0x0 --transform 2,0,0,0,2,0,0,0,1 --output eDP-1 --mode 3840x2400 --pos 0x2880 --primary
You can find the name and the proper default resolution for your monitors by running xrandr
without arguments.
- My external monitor (
DP-1
) has a resolution of 2560x1440
- I need to transform the resolution by a factor of 2
- My laptop (
eDP-1
) has a resolution of 3840x2400
I want to have my external monitor above the laptop.
--pos
is the position of the top left corner of one monitor in the monitor space (the total area occupied by both monitors).
So --pos 0x0
puts the external monitor at the top. To have the laptop below it, I need to get the proper value for the y
coordinate (x
will of course be 0
in this case).
It is the height of the external monitor (1440
) corrected by the transformation (a factor of 2 here):
1440*2 = 2880
.
I am thus using --pos 0x2880
.
For reference, this is what I am using:
OS: Arch Linux
WM: i3
Laptop: 4k
External monitor: 1080p