aboutsummaryrefslogtreecommitdiffhomepage
path: root/src
diff options
context:
space:
mode:
authorNeil <nyamatongwe@gmail.com>2018-04-16 14:26:30 +1000
committerNeil <nyamatongwe@gmail.com>2018-04-16 14:26:30 +1000
commitfba968c24fe513eb523ebd41c8d73b0cfaf36943 (patch)
treec294e8dac353150af43b5d8ea67a92c239eaca6a /src
parent699d75f881ad79e98f9400eeb4a7f86a749b1521 (diff)
downloadscintilla-mirror-fba968c24fe513eb523ebd41c8d73b0cfaf36943.tar.gz
Convert topLine from a screen line to a document line before using it to find a
position.
Diffstat (limited to 'src')
-rw-r--r--src/Editor.cxx3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx
index 16348864d..0a2cf9c7c 100644
--- a/src/Editor.cxx
+++ b/src/Editor.cxx
@@ -2561,7 +2561,8 @@ void Editor::NotifyModified(Document *, DocModification mh, void *) {
pdoc->IncrementStyleClock();
}
if (paintState == notPainting) {
- if (mh.position < pdoc->LineStart(topLine)) {
+ const Sci::Line lineDocTop = pcs->DocFromDisplay(topLine);
+ if (mh.position < pdoc->LineStart(lineDocTop)) {
// Styling performed before this view
Redraw();
} else {