diff options
-rw-r--r-- | src/Editor.cxx | 13 | ||||
-rw-r--r-- | src/SciTE.properties | 4 |
2 files changed, 5 insertions, 12 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx index 3b3e1a99e..c3a4eafb4 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -2087,11 +2087,7 @@ void Editor::LayoutLine(int line, Surface *surface, ViewStyle &vstyle, LineLayou if (ll->validity == LineLayout::llCheckTextAndStyle) { int lineLength = posLineEnd - posLineStart; if (!vstyle.viewEOL) { - int cid = posLineEnd - 1; - while ((cid > posLineStart) && IsEOLChar(pdoc->CharAt(cid))) { - cid--; - lineLength--; - } + lineLength = pdoc->LineEnd(line) - posLineStart; } if (lineLength == ll->numCharsInLine) { // See if chars, styles, indicators, are all the same @@ -2148,10 +2144,7 @@ void Editor::LayoutLine(int line, Surface *surface, ViewStyle &vstyle, LineLayou const int lineLength = posLineEnd - posLineStart; pdoc->GetCharRange(ll->chars, posLineStart, lineLength); pdoc->GetStyleRange(ll->styles, posLineStart, lineLength); - int numCharsBeforeEOL = lineLength; - while ((numCharsBeforeEOL > 0) && IsEOLChar(ll->chars[numCharsBeforeEOL-1])) { - numCharsBeforeEOL--; - } + int numCharsBeforeEOL = pdoc->LineEnd(line) - posLineStart; const int numCharsInLine = (vstyle.viewEOL) ? lineLength : numCharsBeforeEOL; for (int styleInLine = 0; styleInLine < numCharsInLine; styleInLine++) { styleByte = ll->styles[styleInLine]; @@ -2355,7 +2348,7 @@ ColourDesired Editor::TextBackground(ViewStyle &vsDraw, bool overrideBackground, } else { if ((vsDraw.edgeState == EDGE_BACKGROUND) && (i >= ll->edgeColumn) && - !IsEOLChar(ll->chars[i])) + (i < ll->numCharsBeforeEOL)) return vsDraw.edgecolour; if (inHotspot && vsDraw.hotspotBackgroundSet) return vsDraw.hotspotBackground; diff --git a/src/SciTE.properties b/src/SciTE.properties index c323f52cf..1eda9fae4 100644 --- a/src/SciTE.properties +++ b/src/SciTE.properties @@ -2,5 +2,5 @@ # settings made in SciTEGlobal.properties command.build.directory.*.cxx=..\win32 command.build.directory.*.h=..\win32 -command.build.*.cxx=nmake -f scintilla.mak QUIET=1 DEBUG=0 -command.build.*.h=nmake -f scintilla.mak QUIET=1 DEBUG=0 +command.build.*.cxx=nmake -f scintilla.mak QUIET=1 +command.build.*.h=nmake -f scintilla.mak QUIET=1 |