summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authornanahi <130121847+na-na-hi@users.noreply.github.com>2024-02-18 13:57:05 -0500
committerDudemanguy <random342@airmail.cc>2024-02-21 18:55:43 +0000
commitde4f3018912ee1c0904864bb1e0ba314ecf23e24 (patch)
tree5cd0c3b4e9fa5fe9a9282f6177b79852ee8d0adc /etc
parent362959ace3b0843f3977e97e918ceaa80b71b176 (diff)
downloadmpv-de4f3018912ee1c0904864bb1e0ba314ecf23e24.tar.bz2
mpv-de4f3018912ee1c0904864bb1e0ba314ecf23e24.tar.xz
input.conf: bind Ctrl+WHEEL_UP/DOWN to video-zoom
There are good reasons to bind Ctrl+WHEEL_UP/WHEEL_DOWN to video-zoom: - They are ubiquitous and familiar key bindings to represent zooming operations, which are used in all popular web browsers, document viewers, and document editors. - Because WHEEL_UP/WHEEL_DOWN are scaled with high-resolution scrolling input devices like touchpads, this allows smooth zooming. - This makes "pinch to zoom" with touchpads and touchscreens work out of box on Windows, since by default applications receive these key inputs for pinch gesture. - It had been considered to bind these keys to window-scale instead. However, this results in horrible UX as the keybinds work only when the mouse pointer is over the mpv window, and if the window shrinks during this operation, the window below mpv now receives these keybinds, resulting in unwanted zooming for that window, which violates the principle of least surprise.
Diffstat (limited to 'etc')
-rw-r--r--etc/input.conf2
1 files changed, 2 insertions, 0 deletions
diff --git a/etc/input.conf b/etc/input.conf
index cfb97fc7d8..3112d1eea8 100644
--- a/etc/input.conf
+++ b/etc/input.conf
@@ -65,6 +65,8 @@
#ZOOMIN add video-zoom 0.1 # zoom in
#Alt+- add video-zoom -0.1 # zoom out
#ZOOMOUT add video-zoom -0.1 # zoom out
+#Ctrl+WHEEL_UP add video-zoom 0.1 # zoom in
+#Ctrl+WHEEL_DOWN add video-zoom -0.1 # zoom out
#Alt+BS set video-zoom 0 ; set video-pan-x 0 ; set video-pan-y 0 # reset zoom and pan settings
#PGUP add chapter 1 # seek to the next chapter
#PGDWN add chapter -1 # seek to the previous chapter