This is a fix that allows for persistent configuration of tho monitor's pivot rotation. You most create two scripts:
screen-rotate
sudo gedit screen-rotate
add following lines save and exit
#!/bin/bash
if [ "$1" = "right" ]
then
rotate="right"
else
rotate="left"
fi
if xrandr | grep "$rotate ("
then
rotate="normal"
fi
xrandr -o "$rotate"
echo $rotate > ~/.screen-orientation
screen-rotate-setup
sudo gedit screen-rotate-setup
add following lines save and exit
#!/bin/bash
rotate=`cat ~/.screen-orientation`
xrandr -o $rotate
save both scripts to /usr/bin and give them execution permissions to everyone (chmod +x)
Now go to System>Preferences>Sessions, click add and put screen-rotate-setup as the command. Name it as you see fit.
Now create a shortcut somewhere (the taskbar, perhaps?) put as a the command screen-rotate(in case your monitor rotates clockwise) or screen-rotate right(in case your monitor rotates counter-clockwise).
New click on the shortcut, log out and then login again.
Monday, 16 March 2009
Persistent monitor rotation Script
Subscribe to:
Post Comments (Atom)
0 comments:
Post a Comment