Bug 263314 - Okular doesn't work too well with graphics tablets
Summary: Okular doesn't work too well with graphics tablets
Status: RESOLVED FIXED
Alias: None
Product: okular
Classification: Applications
Component: general (show other bugs)
Version: 0.11.1
Platform: Ubuntu Linux
: NOR normal (vote)
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-01-16 14:15 UTC by Martin Zuther
Modified: 2011-01-23 02:34 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In: 4.6.1


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Zuther 2011-01-16 14:15:26 UTC
Version:           0.11.1 (using KDE 4.5.1) 
OS:                Linux

At first, thanks for making such a great free PDF-and-what-not viewer!

I am using a professional graphics tablet (Wacom Intuos3 A5) instead of a mouse.  Most of the time when I left-click on a document's hyperlink in Okular, nothing happens at all.  Only occasionally, Okular follows the link.  The same happens if I right-click on a hyperlink -- most of the time I get the "Add bookmark / Previous bookmark / Next bookmark" popup, and only rarely the expected "Follow link / Copy link address" popup comes up.

This problem is probably not related to the tablet's driver, as using the tablet's mouse works as expected all of the time.  Only when I use the tablet pen, I get the described behaviour.

I think there are two "culprits" here.  The graphics tablet registers mouse clicks by either tipping the pen's tip on the tablet surface (left click) or by holding the pen just above the tablet surface and clicking on one of two pen buttons (right and middle click).  As the tablet has a very high resolution, it registers even minute pen movements, so it is almost impossible to do a click without moving the pen to a veeeery near location (think in micrometers).  But this might be enough to signal "I don't want to follow the hyperlink, let's scroll the document" to Okular.

The second culprit, although not as likely, is that graphics tablets report absolute movement, not relative movement.  That means that a mouse might say "The mouse pointer has moved 1.1 inches to the left and 0.1 inches to the top" whereas a graphics reports "The mouse pointer has moved to position 8.8 / 1.2 inches from the top / left position" (although I honestly don't know whether the zero position actually lies at "top / left" or whether the Linux driver translates absolute to relative positions -- in Windows XP, which I rarely use, this distinction unfortunately DOES matter a lot).

Reproducible: Always

Steps to Reproduce:
Open a PDF containing hyperlinks in Okular.  Find a professional (i.e. high resolution!) graphics tablet and try left- and right-clicking on a hyperlink with the pen.

Depending on the cause of the problem, you *might* simulate this using a mouse by clicking on the hyperlink without releasing the button, then moving the mouse just the tiniest bit (but you'll have to see the pointer move) and finally releasing the mouse button.

Actual Results:  
The link is either not followed (left button) or the wrong popup comes up ("Add bookmark / Previous bookmark / Next bookmark", right button).

Expected Results:  
The link is followed (left button) or the correct popup comes up ("Follow link / Copy link address", right button).

OS: Linux (x86_64) release 2.6.35-24-generic
Compiler: cc
Graphics tablet: Wacom Intuos3 A5
Comment 1 Christoph Feck 2011-01-16 17:52:18 UTC
See also: QApplication::startDragTime() and QApplication::startDragDistance().
Comment 2 Albert Astals Cid 2011-01-23 02:33:32 UTC
SVN commit 1216390 by aacid:

Accept slight pixel movements for detecting mouse clicks
Should help with bug 263314
BUGS: 263314


 M  +7 -3      pageview.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1216390
Comment 3 Albert Astals Cid 2011-01-23 02:34:10 UTC
SVN commit 1216391 by aacid:

Backport Accept slight pixel movements for detecting mouse clicks
Should help with bug 263314
BUGS: 263314
FIXED-IN: 4.6.1


 M  +7 -3      pageview.cpp  


WebSVN link: http://websvn.kde.org/?view=rev&revision=1216391