Created
December 13, 2017 22:34
-
-
Save Deevad/3a1df85a0bd4924f650ff1757e0714cf to your computer and use it in GitHub Desktop.
My wacom Intuos3 A4 xsetwacom script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#! /bin/bash | |
# Setup xsetwacom script for Intuos 3 9x12 | |
# License: CC-0/Public-Domain license | |
# author: deevad | |
# Tablet definition | |
tabletstylus="Wacom Intuos3 9x12 Pen stylus" | |
tableteraser="Wacom Intuos3 9x12 Pen eraser" | |
tabletpad="Wacom Intuos3 9x12 Pad pad" | |
# Reset | |
xsetwacom --set "$tabletstylus" ResetArea | |
xsetwacom --set "$tableteraser" ResetArea | |
#xsetwacom --set "$tabletstylus" RawSample 4 | |
# Screen mapping and keep ratio | |
# xsetwacom get "$tabletstylus" Area | |
# default area : 0 0 60960 45720 | |
xsetwacom --set "$tabletstylus" MapToOutput "HEAD-0" | |
xsetwacom --set "$tableteraser" MapToOutput "HEAD-0" | |
screenX=1920 | |
screenY=1080 | |
Xtabletmaxarea=60960 | |
areaY=$(( $screenY * $Xtabletmaxarea / $screenX )) | |
xsetwacom --set "$tabletstylus" Area 0 0 "$Xtabletmaxarea" "$areaY" | |
xsetwacom --set "$tableteraser" Area 0 0 "$Xtabletmaxarea" "$areaY" | |
# --------- | |
# | | 1 | | |
# | 3 |---| | |
# | | 2 | | |
# |-------| | |
# | 8 | | |
# --------- | |
# button on left | |
xsetwacom --set "$tabletpad" Button 3 "key Control_L" # color picker | |
xsetwacom --set "$tabletpad" Button 1 "key KP_Divide" # '/' | |
xsetwacom --set "$tabletpad" Button 2 "key Shift_L" # resize brush | |
xsetwacom --set "$tabletpad" Button 8 "key e" # color picker | |
xsetwacom --set "$tabletstylus" Button 2 "key Control_L" # color picker | |
xsetwacom --set "$tabletstylus" Button 3 3 # color picker |
Thanks @Deevad for you answer. Maby you know how I could get this functionallity in Mac / Windows ? Maby point me in the rigth direction to save me some Googling :)
Unfortunately, I have no idea @sirhaffy , I have only various distro of Linux at home. I guess your best option is probably the official driver from the Wacom website or I also heard about https://github.com/OpenTabletDriver/OpenTabletDriver , an alternative driver. I hope you'll succeed in your quest.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Hi @sirhaffy , yes it's a GNU/Linux set of xsetwacom rules (for X11). To execute them, you need to save this in a
tablet.sh
script, give it permission to execute, then add the script to the autostart of your desktop environment. If you are on another operating system (or use Wayland), this code will not do anything.