From 2ac44709bd9a9ec8d3ab60a40a81ac7ca3ad1b57 Mon Sep 17 00:00:00 2001 From: Nick Hanley Date: Sat, 15 Jan 2022 17:51:31 -0500 Subject: Add keybind to scroll to image center (#203) There are keybinds for scrolling to the edges of an image but there's no way back to the center. This is particularly annoying while zooming. --- commands.c | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'commands.c') diff --git a/commands.c b/commands.c index aafc510..7b7be62 100644 --- a/commands.c +++ b/commands.c @@ -325,6 +325,11 @@ bool ci_scroll(arg_t dir) return img_pan(&img, dir, prefix); } +bool ci_scroll_to_center(arg_t _) +{ + return img_pan_center(&img); +} + bool ci_scroll_to_edge(arg_t dir) { return img_pan_edge(&img, dir); -- cgit v1.2.3