| 
									
										
										
										
											2016-07-02 16:39:48 +09:00
										 |  |  | #!/bin/sh | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-07-24 15:07:58 +02:00
										 |  |  | xinput set-prop "$(cat ~/.touchpad-name)" "libinput Natural Scrolling Enabled" 1 | 
					
						
							| 
									
										
										
										
											2017-08-01 13:01:45 +02:00
										 |  |  | 
 | 
					
						
							|  |  |  | if [ $# -eq 1 ]; then | 
					
						
							|  |  |  |     display=$1 | 
					
						
							|  |  |  | else | 
					
						
							| 
									
										
										
										
											2018-04-03 17:26:41 +02:00
										 |  |  |     display="$(xrandr | awk '/primary/ { print $1 }')" | 
					
						
							| 
									
										
										
										
											2017-08-01 13:01:45 +02:00
										 |  |  | fi | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2019-03-12 10:12:20 +01:00
										 |  |  | # Required since 2019-03-12, beowulf | 
					
						
							| 
									
										
										
										
											2019-06-23 21:02:52 +02:00
										 |  |  | if xinput list | grep -q "TPPS/2 Elan TrackPoint"; then | 
					
						
							| 
									
										
										
										
											2019-03-12 10:12:20 +01:00
										 |  |  |     xinput set-prop "TPPS/2 Elan TrackPoint" "libinput Accel Speed" -0.2 | 
					
						
							|  |  |  | fi | 
					
						
							| 
									
										
										
										
											2017-08-01 13:01:45 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-07-02 16:15:52 +02:00
										 |  |  | # as on bridge/t490s | 
					
						
							|  |  |  | if xinput list | grep -q "Elan TrackPoint"; then | 
					
						
							| 
									
										
										
										
											2020-08-01 20:32:16 +02:00
										 |  |  |     xinput set-prop "Elan TrackPoint" "libinput Accel Speed" -0.5 | 
					
						
							| 
									
										
										
										
											2020-07-02 16:15:52 +02:00
										 |  |  | fi | 
					
						
							| 
									
										
										
										
											2020-07-06 22:42:28 +02:00
										 |  |  | 
 | 
					
						
							|  |  |  | # Not needed if using regular libinput | 
					
						
							|  |  |  | # if xinput list | grep -q "Elan Touchpad"; then | 
					
						
							|  |  |  | #     xinput set-prop "Elan Touchpad" "Device Accel Constant Deceleration" 3 | 
					
						
							|  |  |  | # fi | 
					
						
							| 
									
										
										
										
											2020-07-02 16:15:52 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2022-07-12 06:48:15 +02:00
										 |  |  | # blind | 
					
						
							|  |  |  | if xinput list | grep -q "Wacom HID 5276 Finger"; then | 
					
						
							| 
									
										
										
										
											2022-07-12 09:19:23 +02:00
										 |  |  |     xinput map-to-output 'Wacom HID 5276 Finger' ${display} | 
					
						
							| 
									
										
										
										
											2022-11-30 10:55:22 +01:00
										 |  |  |     xinput map-to-output 'Wacom HID 5276 Pen Pen (0x81266661)' ${display} | 
					
						
							| 
									
										
										
										
											2022-08-02 08:04:10 +02:00
										 |  |  | fi | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2023-07-13 15:40:21 +02:00
										 |  |  | # sun | 
					
						
							| 
									
										
										
										
											2023-07-14 14:30:59 +02:00
										 |  |  | if xinput list | grep -q "LXT2021:00 29BD:3201"; then | 
					
						
							| 
									
										
										
										
											2023-07-13 15:40:21 +02:00
										 |  |  |    xinput map-to-output 'LXT2021:00 29BD:3201' ${display} | 
					
						
							|  |  |  | fi | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2022-08-02 08:04:10 +02:00
										 |  |  | # nb2 | 
					
						
							|  |  |  | if xinput list | grep -q "ELAN Touchscreen"; then | 
					
						
							|  |  |  |     xinput map-to-output 'ELAN Touchscreen' ${display} | 
					
						
							| 
									
										
										
										
											2022-07-12 06:48:15 +02:00
										 |  |  | fi | 
					
						
							| 
									
										
										
										
											2020-07-02 16:15:52 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-10-09 13:31:37 +02:00
										 |  |  | if xinput list | grep -q Bamboo; then | 
					
						
							|  |  |  |     devfinger="Wacom Bamboo 16FG 4x5 Finger touch" | 
					
						
							| 
									
										
										
										
											2017-08-01 13:01:45 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-10-09 13:31:37 +02:00
										 |  |  |     xinput set-prop "$devfinger" "Device Enabled" 0 | 
					
						
							| 
									
										
										
										
											2017-08-01 13:01:45 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-10-09 13:31:37 +02:00
										 |  |  |     xsetwacom --set "Wacom Bamboo 16FG 4x5 Pen stylus" MapToOutput $display | 
					
						
							|  |  |  |     xsetwacom --set "Wacom Bamboo 16FG 4x5 Pen eraser" MapToOutput $display | 
					
						
							| 
									
										
										
										
											2017-08-01 13:01:45 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-10-09 13:31:37 +02:00
										 |  |  | fi | 
					
						
							| 
									
										
										
										
											2017-08-01 13:01:45 +02:00
										 |  |  | 
 | 
					
						
							| 
									
										
										
										
											2020-08-01 20:32:16 +02:00
										 |  |  | # Only continue if there is wacom stuff | 
					
						
							|  |  |  | if ! xinput list | grep -i wacom -q; then | 
					
						
							|  |  |  |     exit 0 | 
					
						
							|  |  |  | fi | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-08-01 13:01:45 +02:00
										 |  |  | 
 | 
					
						
							|  |  |  | # xinput set-prop "Wacom Bamboo 16FG 4x5 Finger pad" "Device Enabled" 0 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | xsetwacom --set "Wacom Bamboo 16FG 4x5 Pen stylus" mode relative | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | xinput set-prop "Wacom Bamboo 16FG 4x5 Pen stylus" "Device Accel Constant Deceleration" 4 | 
					
						
							|  |  |  | xinput set-prop "Wacom Bamboo 16FG 4x5 Pen stylus" "Device Accel Adaptive Deceleration" 2 | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2018-03-29 16:50:35 +02:00
										 |  |  | xsetwacom --set "Wacom HID 484D Finger touch" MapToOutput "$display" | 
					
						
							|  |  |  | xsetwacom --set "Wacom HID 484D Pen stylus" MapToOutput "$display" | 
					
						
							|  |  |  | 
 | 
					
						
							| 
									
										
										
										
											2017-08-01 13:01:45 +02:00
										 |  |  | # Rotate so usb cable is not disturbing me | 
					
						
							|  |  |  | # xinput set-prop 14 "Evdev Axis Inversion" 1 1 | 
					
						
							|  |  |  | # xsetwacom --set "Wacom Bamboo 16FG 4x5 Pen" MapToOutput LVDS1 | 
					
						
							|  |  |  | 
 | 
					
						
							|  |  |  | exit 0 |