diff options
author | Marko Njezic <unknown> | 2012-04-13 00:16:36 +0200 |
---|---|---|
committer | Marko Njezic <unknown> | 2012-04-13 00:16:36 +0200 |
commit | 65e526dd2a5b1fce59513a7f2720ffbf91c2f310 (patch) | |
tree | 43a613adb396bd23884bd15f4503f79d1c89be04 /src | |
parent | cf376591f1c44cdf9c4b8ab0c5881572a3ae57ec (diff) | |
download | scintilla-mirror-65e526dd2a5b1fce59513a7f2720ffbf91c2f310.tar.gz |
Include wrap indentation in alpha selection when selecting whole lines. Bug #3515555.
Diffstat (limited to 'src')
-rw-r--r-- | src/Editor.cxx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx index 2376af413..4249fb648 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -3248,6 +3248,10 @@ void Editor::DrawLine(Surface *surface, ViewStyle &vsDraw, int line, int lineVis const XYPOSITION spaceWidth = vsDraw.styles[ll->EndLineStyle()].spaceWidth; rcSegment.left = xStart + ll->positions[portion.start.Position() - posLineStart] - subLineStart + portion.start.VirtualSpace() * spaceWidth; rcSegment.right = xStart + ll->positions[portion.end.Position() - posLineStart] - subLineStart + portion.end.VirtualSpace() * spaceWidth; + if ((ll->wrapIndent != 0) && (lineStart != 0)) { + if ((portion.start.Position() - posLineStart) == lineStart && sel.Range(r).ContainsCharacter(portion.start.Position() - 1)) + rcSegment.left -= static_cast<int>(ll->wrapIndent); // indentation added to xStart was truncated to int, so we do the same here + } rcSegment.left = (rcSegment.left > rcLine.left) ? rcSegment.left : rcLine.left; rcSegment.right = (rcSegment.right < rcLine.right) ? rcSegment.right : rcLine.right; if (rcSegment.right > rcLine.left) |