aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authornyamatongwe <unknown>2007-02-20 23:04:56 +0000
committernyamatongwe <unknown>2007-02-20 23:04:56 +0000
commit37212473571503f9a5cb1959075cb4e38d4ec83b (patch)
treeaacb8623ea906c9b6c2f0f746730e646e0338a7d /src
parent693789d480c2f4acbfa74695b8892e4a7fc93e0e (diff)
downloadscintilla-mirror-37212473571503f9a5cb1959075cb4e38d4ec83b.tar.gz
Fix for bug #1663839: stuttered page down doesn't work
if lines are wrapped.
Diffstat (limited to 'src')
-rw-r--r--src/Editor.cxx5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx
index d3d16036b..3070530cc 100644
--- a/src/Editor.cxx
+++ b/src/Editor.cxx
@@ -4022,7 +4022,10 @@ void Editor::PageMove(int direction, selTypes sel, bool stuttered) {
// I consider only the caretYSlop, and ignore the caretYPolicy-- is that a problem?
int currentLine = pdoc->LineFromPosition(currentPos);
int topStutterLine = topLine + caretYSlop;
- int bottomStutterLine = topLine + LinesToScroll() - caretYSlop;
+ int bottomStutterLine =
+ pdoc->LineFromPosition(PositionFromLocation(
+ Point(lastXChosen, direction * vs.lineHeight * LinesToScroll())))
+ - caretYSlop - 1;
if (stuttered && (direction < 0 && currentLine > topStutterLine)) {
topLineNew = topLine;