From a7c1fb0044d621785fef5bc7f6abd577b20e8ff5 Mon Sep 17 00:00:00 2001 From: Neil Hodgson Date: Sat, 22 Feb 2014 10:59:37 +1100 Subject: Stop adding an extra line to scrollable height as that led to cursor up/down movement bugs because different parts of the code disagreed on top line. --- cocoa/ScintillaCocoa.mm | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cocoa/ScintillaCocoa.mm b/cocoa/ScintillaCocoa.mm index a10a2381a..1e9d6e973 100644 --- a/cocoa/ScintillaCocoa.mm +++ b/cocoa/ScintillaCocoa.mm @@ -1633,7 +1633,7 @@ bool ScintillaCocoa::SetScrollingSize(void) { NSScrollView *scrollView = ScrollContainer(); NSClipView *clipView = [ScrollContainer() contentView]; NSRect clipRect = [clipView bounds]; - CGFloat docHeight = (cs.LinesDisplayed()+1) * vs.lineHeight; + CGFloat docHeight = cs.LinesDisplayed() * vs.lineHeight; if (!endAtLastLine) docHeight += (int([scrollView bounds].size.height / vs.lineHeight)-3) * vs.lineHeight; // Allow extra space so that last scroll position places whole line at top -- cgit v1.2.3