Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Read mouse wheel scroll direction on macOS
jkempinger_dv last edited by
I'm trying to detect whether the scroll direction is set to "natural" on macOS. I had assumed that the inverted attribute from the QWheelEvent would provide this, but it is always returning false. Is there a way to read this setting at run-time? It can be read through the macOS defaults system (
defaults read NSGlobalDomain com.apple.swipescrolldirection), but I'm not sure how to access this through Qt.
You can use Objective-C alongside C++. Take a look at the QtMacExtras module for example.