summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAdrian Holfter <git@adrian.holfter.de>2019-05-16 14:39:02 +0200
committerAdrian Holfter <git@adrian.holfter.de>2019-05-16 14:39:02 +0200
commitbbe0f89c242bb11cbcae89aee9110fee56a5f8a2 (patch)
tree9a57e5ed22b826713438f7bbea178f98c2b8d57c
parent6c5d96d0e8bd577cc0a048acacbd3174070b7aef (diff)
implement horizontal scrolling while holding shift (only if
shift-to-scroll is disabled)
-rw-r--r--src/gui/tikzview.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/gui/tikzview.cpp b/src/gui/tikzview.cpp
index 3615685..3479d22 100644
--- a/src/gui/tikzview.cpp
+++ b/src/gui/tikzview.cpp
@@ -149,6 +149,8 @@ void TikzView::wheelEvent(QWheelEvent *event)
} else if (event->angleDelta().y() < 0) {
zoomOut();
}
+ } else if (event->modifiers() & Qt::ShiftModifier) {
+ horizontalScrollBar()->setValue(horizontalScrollBar()->value() + event->angleDelta().y());
}
}