[kate] [Bug 442060] Mac OS Trackpad scroll buggy

Adrian Damian bugzilla_noreply at kde.org
Tue Sep 28 14:44:45 BST 2021


https://bugs.kde.org/show_bug.cgi?id=442060

--- Comment #6 from Adrian Damian <damian.adrian24 at gmail.com> ---
Created attachment 141992
  --> https://bugs.kde.org/attachment.cgi?id=141992&action=edit
repro #3 log

Based on some log combing, I reached this hypothesis:

The scroll stutter happens because "NSEvent: type=ScrollWheel" events either
stop being emmited or stop being processed, and a second-long gesture is
started and keeps being updated as I keep moving my fingers on the trackpad a
second time.

I can't tell if the gesture starts because ScrollWheel NSEvents stop happening,
OR if the gesture being started prevents the ScrollWheel events in the first
place.

Next things I plan to do to narrow this further (any suggestions are *highly*
appreciated, since I'm really out of my depth here):

* disable gestures (if possible), and see if the stutter still happens
* search for Qt bugs having to do with gestures and scrolling / mouse events

---

I obtained the log by starting Kate at the end of a file that's ~2k lines long,
and scrolling up a few times (details on the log below).

Timeline (seconds since app start, matching the log output):

* ~6 start scrolling
* ~6.8 scroll starts happening on screen

* 6.29 .. 8.58 (repeating every ~.01s, interleaved in various ways)

      QGestureManager:Recognizer: ignored the event:
      Sending NSEvent: type=ScrollWheel
      Qt::ScrollUpdate
      Sending NSEvent: type=Gesture
      touchesMovedWithEvent

      Qt::ScrollMomentum

* 8.58 these stop appearing as frequently

      Qt::ScrollUpdate
      Sending NSEvent: type=ScrollWheel
      Qt::ScrollMomentum

  type=Gesture, touchesMovedWithEvent and "ignored the event" keep appearing

* ~8.6 scroll stutters visibly (it's likely at this point I've lifted my
fingers off the trackpad and and put them down again to start scrolling a
second time)
* ~10.1 scroll stutters visibly (same as above)

* 10.41 "QGestureManager:Recognizer: maybe gesture"

      touchesEndedWithEvent
      QGestureManager:Recognizer: not gesture:
      touchesBeganWithEvent
      QGestureManager:Recognizer: maybe gesture:
      QGestureManager::filterEventThroughContexts: 
      started gesture was delivered and accepted by
KateViewInternal(0x7f85d9be3660)

* 10.46 (repeated until 13.07) "QGestureManager:Recognizer: gesture triggered"

      QGestureManager::deliverEvents: sending to
KateViewInternal(0x7f85d9be3660) gestures:
      touchesMovedWithEvent
      QGestureManager:Recognizer: gesture triggered:
      QGestureManager::filterEventThroughContexts: 
          triggered: QSet(Custom
gesture(state=GestureUpdated,hotSpot=...,type=Qt::GestureType(258)))
      QGestureManager::deliverEvents: 

      (every other 5-10 of the above)
      QGestureManager: we were asked to consume the event:

      (very few; ~8 during 10, 2 during 11, 1 during 12)
      Qt::ScrollUpdate

* ~11.1 scroll stops entirely

* 13:07

      (first time after 10.41)
      Sending NSEvent: type=ScrollWheel

      Qt::ScrollEnd
      touchesEndedWithEvent

--- 

"repro #3 timeline full" has a more complete timeline.

"repro #3 log" has the full log, obtained with:

QT_LOGGING_RULES="*=true" \
/Applications/kate\ 2.app/Contents/MacOS/kate ~/tomatoes.md 2>&1 \
| ts -s '%.S' \
| grep -Ev \
    -e qt.widgets.painting \
    -e qt.qpa.backingstore \
    -e kf.texteditor \
    -e kf.sonnet. \
| tee ~/Desktop/repro-3.log

The Kate used was kate-21.08.1-1354-macos-64-clang.dmg (KDE Frameworks 5.86.0,
Qt 5.15.2 (built against 5.15.2)).

-- 
You are receiving this mail because:
You are watching all bug changes.



More information about the kde-mac mailing list