Navigation

    Qt Forum

    • Login
    • Search
    • Categories
    • Recent
    • Tags
    • Popular
    • Search
    • Unsolved
    1. Home
    2. Tags
    3. gesture
    Log in to post

    • UNSOLVED Zoom in and out of a QTextEdit with touch pad gestures?
      General and Desktop • qtextedit zoom gestures gesture • • legitnameyo  

      13
      0
      Votes
      13
      Posts
      1143
      Views

      The following partially works and I post in the hopes that someone might get an idea that will fix my issue :) bool ZoomCode::event(QEvent *event) { if (event->type() == QEvent::NativeGesture) { return gestureEvent(static_cast<QNativeGestureEvent*>(event)); } return QWidget::event(event); } bool ZoomCode::gestureEvent(QNativeGestureEvent *e) { float value = e->value(); textEdit->setFontPointSize(NULL); // zoom does not work without this textEdit->selectAll(); // some part of the text has to be selected before the zoom in the text starts to work. It does NOT matter if it is the WHOLE text or just a character in the text, just as long as something gets highlighted. Afterwards, nothing has to be highlighted again for the zoom to work. The zoom works on the whole text, no matter what part has been highlighted. if(value >0) { zoomIn(value + 5); // + 5 to add some zoom strength } else if(value < 0) zoomOut(value - 5); // -5 to add some zoom strength } }
    • UNSOLVED Touch gesture recognition with a custom QQuickPaintedItem?
      General and Desktop • touch mouse event qquickpaintedit touch issue gesture • • RaDq1  

      7
      1
      Votes
      7
      Posts
      2791
      Views

      As I now understand it there is no easy way to recognize gestures inside the c++ part of a Qt Quick 'QQuickPaintedItem' inherited class, is that correct? I need both pan and pinch in my c++ class so if i dont want to write my own recognition code should I then inherit my class from both 'QQuickPaintedItem', PinchArea and Flickable? that doesn't seem right? (besides that they are declared in private header files like qquickpincharea_p.h) found the same request (also without an statisfying answer here: https://forum.qt.io/topic/61108/recognize-arbitrary-gestures-in-qt5-like-gesturearea-in-qt4 )
    • UNSOLVED QML & touchscreen gestures
      QML and Qt Quick • gesture swipe • • morte  

      1
      0
      Votes
      1
      Posts
      554
      Views

      No one has replied

    • UNSOLVED Can't catch TapAndHoldGesture
      General and Desktop • gesture qgestureevent • • AlaaM  

      1
      0
      Votes
      1
      Posts
      542
      Views

      No one has replied

    • UNSOLVED Qt Swipe Gesture not working
      General and Desktop • gestures gesture swipe qgestureevent • • Jari  

      14
      0
      Votes
      14
      Posts
      10433
      Views

      @QTUserForAndroid This should help to 'mark as solved' and other forum inquiries: https://forum.qt.io/topic/62700/hitchhiker-s-visual-guide-to-the-qt-forum
    • Problem creating a new custom gesture
      General and Desktop • qtcreator qt5.4 gesture qgesturerecogni • • Karen Zurutuza  

      10
      0
      Votes
      10
      Posts
      3283
      Views

      Can you show your class and its implementation ?
    • QPanGesture on Android
      Mobile and Embedded • android qgraphicsview gesture qpangesture • • GuillaumeG  

      1
      0
      Votes
      1
      Posts
      528
      Views

      No one has replied