Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Users
    • Groups
    • Search
    • Unsolved

    Swipe Gesture not Recognized on Macbook Pro (OSX Mavericks) (Qt 5.3)

    General and Desktop
    3
    5
    1600
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • J
      jxem last edited by

      It seems that the swipe gesture is not recognized on the macbook pro using the image gestures example. The pinch / rotate works just fine.

      There is a closed bug Qt QTBUG-28126 that reports this as fixed in Qt 5.2. I'm running Qt5.3.

      Has anybody gotten the SwipeGesture to work a macbook pro with the trackpad?
      Or do I need to resort to creating a customer recognizer for this basic function?

      Any help is appreciated.

      Paris 1 Reply Last reply Reply Quote 0
      • S
        Sam last edited by

        Just for info, the swipe gesture in Qt require 3 touch points to activate on a touchscreen.

        Don't have much info with trackpad, need to check the source code in Qt.

        Regards
        Sam

        1 Reply Last reply Reply Quote 0
        • J
          jxem last edited by

          @sam: Thanks for the info.

          That might be the problem. The MacBook Pro grabs the 3-point swipe gesture to show a multi-desktop view, which might explain why I never see that gester event. I wonder if anyone has been able to get this to work on the mac with a trackpad.

          1 Reply Last reply Reply Quote 0
          • S
            Sam last edited by

            Other than that you can also write your custom gesture by sub classing "QGestureRecognizer":http://qt-project.org/doc/qt-5/qgesturerecognizer.html

            Have a look at this "example":http://developer.nokia.com/community/wiki/Custom_Swipe_Gestures_in_Qt

            1 Reply Last reply Reply Quote 0
            • Paris
              Paris @jxem last edited by

              @jxem This is probably too late, but I just wanted to write this answer for reference.

              If you are using a Trackpad:

              1. go to System Preferences > Trackpad
              2. Select 'More Gestures'
              3. Change 'Swipe between pages' to 'Swipe with three fingers'
              4. Then you can use three fingers to activate the Swipe Gesture in your Qt application.
              1 Reply Last reply Reply Quote 0
              • First post
                Last post