[Qt-interest] Gestures

Denis Dzyubenko shadone at gmail.com
Mon Jun 7 12:20:07 CEST 2010


Hi Carl,

On 2 June 2010 23:56, Carl Snellman <carl.snellman at gmail.com> wrote:
> I have a Dell Latitude XT2, Win7Pro with multitouch support, and I'm
> trying to get gestures working. I tried the "imagegestures"
> application under 4.7/examples/gestures, and for some reason, I can
> get gesture events (QPanGestures and QPinchGestures) only when I have
> TWO fingers touching the screen. No gestures at all with one finger,
> and no QSwipeGestures at all. Is this a known issue? I understood that

On Windows7 the single-finger-pan gesture should work in all
scrollable widget - that is a special case - to behave the same as
native windows applications. Otherwise it is two-finger. If you want
to implement single finger panning you can make your own
QGestureRecognizer-subclass for the existing QPanGesture and handle
QTouchEvent with just one finger pressed there.

> the platform supposed to recognize also one-finger pan/swipe gestures
> (even the image  @
> http://doc.qt.nokia.com/4.6/qpangesture.html#details shows only one
> finger :)
>
> Secondly, I ran the same app on N900 device, no gesture events at all.
> Has anyone been able get gestures working on Maemo?

That is expected - there are no touch events on N900 - that is a
single-touch device and touch are only sent as mouse events. Gestures
that come with Qt are touch-based, implemented using QTouchEvents, so
they wont work out of the box there.

-- 
Best regards,
Denis.




More information about the Qt-interest-old mailing list