From 5f69661346106144477535f5676f911860501085 Mon Sep 17 00:00:00 2001 From: malc Date: Mon, 1 Aug 2011 21:30:32 +0400 Subject: [PATCH] Disable 'Z', the calculations are wrong (due to scroll bar subtraction) --- KEYS | 1 - main.ml | 12 ------------ 2 files changed, 13 deletions(-) diff --git a/KEYS b/KEYS index 41ce10a..0847f1b 100644 --- a/KEYS +++ b/KEYS @@ -26,7 +26,6 @@ o - switch to outline mode m - create named bookmark ~ - create quick bookmark z - crop -Z - zoom to height r - reload document P - "presentation" mode a - autoscroll diff --git a/main.ml b/main.ml index a227b6e..1391a73 100644 --- a/main.ml +++ b/main.ml @@ -1071,18 +1071,6 @@ let viewkeyboard ~key ~x ~y = enttext (Some (c, "", Some (onhist state.hists.pat), textentry, ondone (c ='/'))) - | 'Z' -> - let maxh = - List.fold_left (fun m (_, _, h) -> max h m) 0 state.pages - in - let zoom = float state.h /. float maxh in - if zoom < 1.0 - then ( - conf.zoom <- zoom; - state.text <- Printf.sprintf "zoom is %3.1f%%" (100.0*.conf.zoom); - reshape state.winw state.h; - ) - | '+' when Glut.getModifiers () land Glut.active_ctrl != 0 -> conf.zoom <- min 2.2 (conf.zoom +. 0.1); state.text <- Printf.sprintf "zoom is %3.1f%%" (100.0*.conf.zoom); -- 2.11.4.GIT