Add dysfunctional xsetwacom udev rule for tablet
This commit is contained in:
parent
d7ac24fd54
commit
4b17b41ff0
2 changed files with 32 additions and 1 deletions
|
@ -1,11 +1,30 @@
|
||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
wacom-config = pkgs.substituteAll {
|
||||||
|
name = "wacom-config";
|
||||||
|
src = ../wacom-config.sh;
|
||||||
|
dir = "bin";
|
||||||
|
isExecutable = true;
|
||||||
|
};
|
||||||
|
in
|
||||||
{
|
{
|
||||||
services = {
|
services = {
|
||||||
# dconf is required for setting GTK themes, see home.nix
|
|
||||||
dbus.packages = with pkgs; [ dconf ];
|
dbus.packages = with pkgs; [ dconf ];
|
||||||
|
# $ nix-shell -p usbutils
|
||||||
|
# $ lsusb
|
||||||
|
# ID <idVendor>:<idProduct>
|
||||||
|
# Gets stored in /etc/udev/rules.d/99-wacom.rules
|
||||||
|
udev.extraRules = ''
|
||||||
|
ACTION=="add",
|
||||||
|
SUBSYSTEMS=="usb",
|
||||||
|
ATTRS{idVendor}="056a",
|
||||||
|
ATTRS{idProduct}="0302",
|
||||||
|
RUN+="${wacom-config}/bin/wacom-config"
|
||||||
|
'';
|
||||||
xserver = {
|
xserver = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
wacom.enable = true;
|
||||||
libinput = {
|
libinput = {
|
||||||
enable = true;
|
enable = true;
|
||||||
touchpad.tapping = true;
|
touchpad.tapping = true;
|
||||||
|
|
12
wacom-config.sh
Executable file
12
wacom-config.sh
Executable file
|
@ -0,0 +1,12 @@
|
||||||
|
# -----------------------------
|
||||||
|
# Desktop monitor configuration
|
||||||
|
# -----------------------------
|
||||||
|
# xsetwacom --list devices | grep -oP '(?<=id:\s)\w+' | while read -r id ; do
|
||||||
|
# xsetwacom set $id MapToOutput 1920x1080+1920+0
|
||||||
|
# done
|
||||||
|
|
||||||
|
touch /home/elnu/wacom-ran
|
||||||
|
|
||||||
|
/run/current-system/sw/bin/xsetwacom set "Wacom Intuos PT S Pad pad" Button 1 "key ctrl ["
|
||||||
|
/run/current-system/sw/bin/xsetwacom set "Wacom Intuos PT S Pad pad" Button 3 "key ctrl ]"
|
||||||
|
/run/current-system/sw/bin/xsetwacom set "Wacom Intuos PT S Pen stylus" Button 3 "key ctrl z"
|
Loading…
Add table
Reference in a new issue