aboutsummaryrefslogtreecommitdiffstats
path: root/main.c
diff options
context:
space:
mode:
authorBert <ber.t@gmx.com>2011-02-03 16:14:49 +0100
committerBert <ber.t@gmx.com>2011-02-03 16:14:49 +0100
commitc6556f8cc7a90909b2dd71747ab605954a3f7892 (patch)
treea5cf1a0b10f0db53b145fa507bc70dcd4180c9bf /main.c
parentbad9a70a48ff38f0d1e22fdedfcaa2241882a0bf (diff)
downloadnsxiv-c6556f8cc7a90909b2dd71747ab605954a3f7892.tar.zst
New key mappings: 0/w, zoom to 100%/to fit window
Diffstat (limited to 'main.c')
-rw-r--r--main.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/main.c b/main.c
index e618288..5a278b3 100644
--- a/main.c
+++ b/main.c
@@ -284,6 +284,13 @@ void on_keypress(XKeyEvent *kev) {
case XK_minus:
changed = img_zoom_out(&img);
break;
+ case XK_0:
+ changed = img_zoom(&img, 1.0);
+ break;
+ case XK_w:
+ if ((changed = img_fit(&img, &win, 1)))
+ img_center(&img, &win);
+ break;
/* panning */
case XK_h: