• We’re currently investigating an issue related to the forum theme and styling that is impacting page layout and visual formatting. The problem has been identified, and we are actively working on a resolution. There is no impact to user data or functionality, this is strictly a front-end display issue. We’ll post an update once the fix has been deployed. Thanks for your patience while we get this sorted.

Xrandr Issues: Dual monitor alignment. [Solved]

Tarvaln

Senior member
Solution:
I had to add a "sleep" command to my monitor script that was being run on login. Using Startup and Sessions under XFCE I made a startup script that points to "~.home/#####/.screenlayout/default.sh". "#####" is the user name.

default.sh contains:

#!/bin/sh
sleep 1
xrandr --output DVI-0 --mode 1024x768 --pos 0x0 --rotate normal --output HDMI-0 --mode 1280x720 --pos 1024x0 --rotate normal --set underscan on --set "underscan hborder" 25 --set "underscan vborder" 15

It's silly but, that Xrandr command needs a one second delay to be able to process that "--pos" command on login properly.

I'm having an issues getting part of a xrandr command to work on log in. I'm using Debain 'Jessie' and XFCE.

xrandr --output DVI-0 --mode 1024x768 --pos 0x0 --rotate normal --output HDMI-0 --mode 1280x720 --pos 1024x0 --rotate normal --set underscan on --set "underscan hborder" 25 --set "underscan vborder" 15

The underscan part of the command works fine, but the pos commands don't do anything on login. The whole command will work if I use it in terminal though.

Things I've tried:

Using Startup and Session:
Making a startup script with the command. (The underscan part works but the pos does not.)

Making a default.sh file with the command using ARandR and using that as part of the startup script.


I have no idea why the pos part of this command won't work on login but will work after login.

Any suggestions would be appreciated. Thanks!
 
Last edited:
It may be a timing thing with the screen initialization. I had similar issues with xrandr and can't remember how I got it working, but ultimately, I had to script things to run after login... I switched jobs and lost my workstation or I'd look it up for you.
 
Uhh... the solution is the first thing you read man. 🙂

I had to add a "sleep" command to my monitor script that was being run on login. Using Startup and Sessions under XFCE I made a startup script that points to "~.home/#####/.screenlayout/default.sh". "#####" is the user name.

default.sh contains:

#!/bin/sh
sleep 1
xrandr --output DVI-0 --mode 1024x768 --pos 0x0 --rotate normal --output HDMI-0 --mode 1280x720 --pos 1024x0 --rotate normal --set underscan on --set "underscan hborder" 25 --set "underscan vborder" 15

It's silly but, that Xrandr command needs a one second delay to be able to process that "--pos" command on login properly.
 
Back
Top