Skip to content

dimaj/XPPenTablet.spoon

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

XPPenTablet.Spoon

This is a spoon (module) to a great piece of sotware called hammerspoon

The purpose for this spoon is to modify monitor mapping settings to the XP-Pen tablet devices without having to open up PenTabletSettings application, since PenTabletSettings appliation does not provide a way to configure monitor mapping based on a running application settings.

This is great when you want to scope your tablet's mapping to a single application window.

Installation

To install this spoon simply run the following command:

git clone https://github.com/dimaj/XPPenTablet.spoon ~/.hammerspoon/Spoons/XPPenTablet.spoon

Sample Configuration

Add the following block to your hammerspoon configuration file:

spoon.SpoonInstall:andUse("XPPenTablet", {
    config = {
        deviceName = "DEV_6298_3936",
        configLocation = "~/.PenTabletConfig/com.ugee.PenTabletSettings.plist"
    },
    hotkeys = {
        current_window = {{"shift", "alt"}, "w"}
    },
    start = true
})

This will install this spoon for you and map Shift + Alt + W keys to updating currently active window as mapping area of your tablet.

Configuration:

Option Name Description Required?
config.deviceName Internal name of your drawing tablet. More informataion on how to get it can be found here yes
config.configLocation Location where PenTabletSettings application looks for configuration data. Defaults to ~/.PenTabletConfig/com.ugee.PenTabletSettings.plis no
start must be set to true to initalize this module yes

API Documentation

Method Name Description Parameters
updateForActiveWindow() Updates config based on currently active window
updateConfigForApp(appName) Updates config based on the main window of specified application appName - Application name to bind table to. E.g. Skitch

About

Hammerspoon Spoon for updating XP-Pen window configuration

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages