Bug Description

SRU Justification:

Impact: Wacom tablet users rely on pressure information for drawing in applications like Krita and Pencil. When the multitouch Qt patches were added to Natty, they disabled the pressure support. This is a fairly major regression of functionality.

How Addressed: The multitouch patch disabled XInput 1.x support in favor of XInput 2.1 support. According to the original patch developer, Denis Dzuybenko, this was likely an oversight due to how the patch was developed. After re-enabling XInput 1.x support, pressure data from Wacom tablets began working, and touch input functioned normally.

Test Case: Install krita or pencil and try to draw with a wacom tablet. See it not work. Install the updated package. Try again. See it work. Note: This test case requires specialized hardware to execute.

Regression Potential: Minimal. This patch merely re-enables lost functionality. The only concern is whether this will disrupt the XInput 2.1 multitouch functionality, but in theory it should not and testing shows this to be the case.

-----

I've noticed Wacom pressure is broken with QT applications only: it works with gimp and Mypaint,
but not in Krita or Pencil (I'm using Krita git-master development version, so I couldn't make a report on Krita package but it is concerned too.. I installed Pencil just to confirm it happens also with a package from the repository, and it's almost the only other pressure-sensitive drawing QT application I know ).
Some idea: I reported this bug to Krita developers, one of them thinks it may be caused by some "Ubuntu specific" modifications for tablet-pc, as it doesn't happen on a Debian with the same version of KDE+QT+linuxwacom…

TEST CASE: Install krita or pencil and try to draw with a wacom tablet. See it not work. Install the updated package. Try again. See it work. Note: This test case requires specialized hardware to execute.

qt4-x11 is a long build, so don't expect it to be available immediately, but once it's built, I would appreciate it if someone who is having this problem would check and see if removing the patch solves the problem.

I've uploaded this for review by ubuntu-sru. They will have to decide if it goes in or not. Ultimately I think that fixing the regression trumps delivering the new feature promised by the patch. Perhaps the uTouch developers will come up with an alternative solution that fixes the regression without dropping the feature, but if they don't then I believe this should go in.

There is another pending qt4-x11 SRU, so it's appropriate that that one be verified and moved to natty-updates before this one is accepted, so there is a bit of time for them to look into it.

I have this problem too since upgrading to 11.04 which is a royal pain in the * when developing a tablet application in QT. The tablet is working fine as can be confirmed by using gtk apps so I don't think recording input events will be useful at all. This might be caused by an old issue - it used to be that QT had the names 'stylus', 'pen', and 'eraser' hardcoded into it. If the devices are called something else then QT just processes pen and eraser as mouse events hence no pressure information.

Ubuntu 9.04 renamed the wacom devices and broke the tablet events on QT but this could be fixed by rewriting the names using HAL. 10.10 worked fine but I have a mongrel of an installation.

We need a recording so developers who don't have wacom tablets can reproduce the problem. I have read through the patch in question multiple times (I originally pushed it into Ubuntu too), and I have no clue yet how it is causing issues. There are many variables at play here, and getting a recording of the input device is essential to helping us develop and fix and verify that it is working properly.

I see that Sven has had trouble recording the input device. This may occur if the X synaptics or wacom input modules are used. Please confirm with input module you are using by attaching /var/log/Xorg.0.log.

Your tablet is using the X wacom input module, which upon further inspection appears to grab the evdev device node. This is why the device.record file was empty when you tried to record the events.

I will attach two new wacom input module packages (one amd64, one i386) that do not grab the evdev device node. This should not cause any issues, and it will allow you to record the events. Please install the appropriate package and repeat the steps outline in comment #11.

Both Animtim and I get the same problem. With the PPA, wacom returns strange results. You can see this in Krita, in the way that every stroke drawn doesn't start where the stylus actually is, but from some point to the top left corner (presumably 0,0) to the point where the stylus first makes contact. It's very odd, and yet it can be fixed instantly by purging the PPA. Strokes drawn with another device, like the mouse are not affected.

Thanks for providing a recording of your device. To use the recording I also need the device.prop file. Please follow the instructions in comment #11 to generate the file and then attach it to this bug report.

The XInput 2.1 multitouch patch disabled XInput 1.x support, which tablet support depends on. The usage of both XInput versions simultaneously should not be a problem, and a fix to the multitouch patch to allow this appears to work properly for both tablet and multitiouch test cases.

I have requested a merge review of the changes.

I have also uploaded a test version of the package to ppa:utouch-team/unstable with version 4.7.3-1ubuntu4~test1. Once it has built, please test it out to verify it works properly.

I've just tried your ppa:utouch-team/unstable (on Natty), unfortunately it doesn't fix the bug, still no pressure in Krita.

(Of course I first did ppa-purge ppa:kitterman/ppa , as his fix worked for some time until some system update on May 31 where it started to have a different bug making it unusable (as Shaved Wookie reported).

Excuse the dumb question, but what exactly should be version 4.7.3 ? Only packages that I see being version "1.7.3" in Synaptic are related to xpilot: xpilot-ng/-ng-nlient-sdl/-ng-client-x11/-ng-common/-ng-server/-ng-utils

I am guessing you don't have xserver-xorg-input-evdev installed. Note that in 11.04, the xserver-xorg-input-wacom input module has been moved to universe. This means it is no longer officially supported by Canonical, and it is not installed by default. Qt only understands the pressure data coming from the xserver-xorg-input-wacom input module, so you need to manually install it and log out and back in before pressure will start working.

I had only pushed the fix to the Oneiric series of the ppa, but to make it easier I have pushed it to the natty series as well. Once it finishes building, please upgrade to the qt4-x11 packages with version 4.7.2-0ubuntu6.2~utouch2. Hopefully with this version of the qt libraries and xserver-xorg-input-wacom pressure should work again.

There was a simple packaging error in the qt4-x11 package I pushed to ppa:utouch-team/unstable for Natty. I have uploaded a new version and verified that pressure is working in Pencil using the device recording attached to this bug. Please retest.

For reference, the qt4-x11 package version from the ppa that I tested was 4.7.2-0ubuntu6.2~utouch3.

Well, now it works exactly like with Scott Kitterman's ppa, that is in Krita there's pressure but there's a strange bug with ghost lines being drawn from the border of the canvas to thecursor. It worked right before, until some update that happened on MAy 31, since when there's this new bug. You can try with the Krita 2.3 package in the repository.

What you are seeing is that the Qt issue is fixed, but that there is likely an issue with either the X server or the wacom input module that is causing the cursor to jump to the corner at times. This should be filed as a separate bug. Please use "ubuntu-bug xserver-xorg-input-wacom" to file the new bug.

Accepted qt4-x11 into natty-proposed, the package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Sorry for last comments, actually the remaining bug is probably in xserver-xorg-core
(as reported in bug #799202 , pressure in Krita works fine using xserver-xorg-core 2:1.10.1-1ubuntu1 , but after updating it
to 2:1.10.1-1ubuntu1.1 it doesn't work right anymore…)