Hi Guys,

I just wiped my Gentoo box and switched to Debian. Everything works well
out of the box, except wacomcpl. There are two issues with this:

    1. Debian doesn't ship wacomcpl along with the other wacom tools. (I
       have no idea why, but there is a bug filed against it.)

    2. It doesn't work anyway :).

The issue is that

    xsetwacom list dev

returns nothing. I know xsetwacom is being redesigned right now, so this
is probably not an issue in the latest version (Debian ships 0.8.3.2 in
testing).

Most of wacomcpl's functionality can be done by RTFM + xsetwacom, so
it's not a bother for me. The notable exception however is stylus
calibration. One needs an interface to get the calibration parameters
right.

I'm attaching a GTK+Perl script I use for stylus calibration modified to
work under such circumstances. The differences from wacomcpl are

    1. This only calibrates the stylus. No functionality for other
       things.

    2. It gets a list of devices from "xsetwacom list dev". If this
       fails, then it looks for the devices from the environment
       variables WACOM_*.

    3. It saves the calibration parameters to ~/calibrate.X (where X is
       the current tablet rotation). I found that I hold my tablet
       differently in each rotation, so just automatically rotating the
       calibration parameters (as done by the driver) gave me bad
       results. This way, I save my per rotation calibration parameters,
       and then source it automatically on startup / every time my
       tablet is rotated via

            tablet_rotation=$(xsetwacom get "$WACOM_STYLUS" Rotate)
            [[ -f ~/.calibrate.$tablet_rotation ]] && \
                source ~/.calibrate.$tablet_rotation
        
    4. It doesn't touch ~/.xinitrc :). [The old wacomcpl always messed
       mine up. I think this was because my ~/.xinitrc was a symlink,
       and contained quite a few if/then/else clauses, since I use the
       same file on multiple setups]

The "-h" output of my script is below, and the script is attached. Feel
free to use (or not to use) it as you see fit,

GI

bash$ calibrate -h
calibrate: Utillity to calibrate your WACOM devices.

OPTIONS:

    --window-offset N, -o N
        Offset from screen edge to draw the calibration windows.
    --window-width N, -w N
        Width of calibration windows
    --only-reset, -r
        Only reset the calibration parameters to default and exit.
    --nosave
        Don't save calibration parameters to ~/.calibrate.X
    --help, -h
        Print this help and exit
    --debug, -d
        Print debugging information.

-- 
'Common' Proof Techniques:
6. Proof by Similarity -- "The other 253 cases are analogous"

Attachment: calibrate.pl
Description: Perl program

Attachment: pgp1B9ZtvB72p.pgp
Description: PGP signature

------------------------------------------------------------------------------
This SF.Net email is sponsored by the Verizon Developer Community
Take advantage of Verizon's best-in-class app development support
A streamlined, 14 day to market process makes app distribution fast and easy
Join now and get one step closer to millions of Verizon customers
http://p.sf.net/sfu/verizon-dev2dev 
_______________________________________________
Linuxwacom-devel mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/linuxwacom-devel

Reply via email to