~scriptsdisplay
10 itemsDownload ./*

10 itemsDownload ./*

..
ana-wall-login.sh
ana-wall-next.sh
ana-wall-refresh.sh
ana-wall.sh
brightness.sh
brightness_change
keep-on.sh
screen-dim
screenshot.sh
xorient.sh


displayxorient.sh
97•  4 months ago•  DownloadRawClose
4 months ago•  97

{}
#!/bin/bash

orient="$1"
if [ -z "$orient" ]; then
    orient="landscape"
fi

if [ ! -z "$2" ]; then
    if [ "$2" == "-l" ]; then
        sleep 3
    fi
fi

matrices="0 0 0 0 0 0 0 0 0"
case "$orient" in
    "landscape")
        #matrices="0 -1 1 1 0 0 0 0 1"
        #matrices="0 0 0 0 0 0 0 0 0"
        matrices="0 1 0 -1 0 1 0 0 1" # default twily
        #matrices="0 -1 1 1 0 0 0 0 1"
        xrandr -o right
        ;;
    "landscape-invert")
        #matrices="-1 0 1 0 -1 1 0 0 1"
        matrices="0 -1 1 1 0 0 0 0 1" # default twily
        xrandr -o left
        ;;
    "portrait")
        matrices="0 0 0 0 0 0 0 0 0" # default twily
        xrandr -o normal
        ;;
    "portrait-invert")
        #matrices="0 0 0 0 0 0 0 0 0"
        matrices="-1 0 1 0 -1 1 0 0 1" # default twily
        xrandr -o inverted
        ;;
esac

name="Wacom HID 4809 Finger touch"

sleep 1
#xinput set-prop "Wacom HID 4809 Finger touch" --type=float "Coordinate Transformation Matrix" 0 0 0 0 0 0 0 0 0
xinput set-prop "$name" --type=float "Coordinate Transformation Matrix" $matrices

#~/scripts/display/ana-wall-refresh.sh
~/scripts/display/ana-wall-login.sh # for keep-on.sh

# find name using $ xinput --list
#
#⎡ Virtual core pointer                    	id=2	[master pointer  (3)]
#⎜   ↳ Virtual core XTEST pointer              	id=4	[slave  pointer  (2)]
#⎜   ↳ Wacom HID 4809 Pen stylus               	id=10	[slave  pointer  (2)]
#⎜   ↳ Wacom HID 4809 Finger touch             	id=11	[slave  pointer  (2)]
#⎜   ↳ Wacom HID 4809 Pen eraser               	id=16	[slave  pointer  (2)]
#⎣ Virtual core keyboard                   	id=3	[master keyboard (2)]
#    ↳ Virtual core XTEST keyboard             	id=5	[slave  keyboard (3)]
#    ↳ Power Button                            	id=6	[slave  keyboard (3)]
#    ↳ Video Bus                               	id=7	[slave  keyboard (3)]
#    ↳ HP Bluetooth Keyboard K4000 Keyboard    	id=8	[slave  keyboard (3)]
#    ↳ sof-bytcht rt5672 Headset               	id=9	[slave  keyboard (3)]
#    ↳ Intel HID events                        	id=12	[slave  keyboard (3)]
#    ↳ gpio-keys                               	id=13	[slave  keyboard (3)]
#    ↳ gpio-keys                               	id=14	[slave  keyboard (3)]
#    ↳ Dell WMI hotkeys                        	id=15	[slave  keyboard (3)]

Top
©twily.info 2013 - 2024
twily at twily dot info



2 158 918 visits
... ^ v