These configurations have been tested on Manjaro with XFCE.
Working perfectly on 2 monitors:
1920x1080p
3840x2160p
First, you will need to download the xorg-xrandr package:
Arch / Manjaro
sudo pacman -S xrandr-xorg
Debian / Ubuntu
sudo apt update && sudo apt install x11-xserver-utils
This script will probably change over the time, so you need to know the name of the monitors and it's respective locations, read the xrandr documentation.
Create a file called display.sh and paste the script below:
#!/bin/sh
xrandr --output HDMI-A-0 --auto --pos 0x1080 --output DisplayPort-2 --scale 0.70x0.70 --pos 1920x0 --right-of HDMI-A-0
Then make the it executable:
chmod 755 display.sh
After that, move the script to: /usr/local/bin
sudo mv display.sh /usr/local/bin
Edit the file /etc/lightdm/lightdm.conf and uncomment the line: display-setup-script= and add the path to your script:
display-setup-script=/usr/local/bin/display.sh
- https://forum.manjaro.org/t/solved-make-xrandr-permanent/69859/4
- https://superuser.com/questions/485120/how-do-i-align-the-bottom-edges-of-two-monitors-with-xrandr
- https://wiki.archlinux.org/index.php/Xrandr
- https://wiki.archlinux.org/index.php/Multihead
- https://unix.stackexchange.com/questions/450835/how-to-execute-command-before-user-login-on-linux
- Test in another desktop environment (Gnome, KDE).