diff options
author | nyamatongwe <devnull@localhost> | 2009-08-11 23:57:40 +0000 |
---|---|---|
committer | nyamatongwe <devnull@localhost> | 2009-08-11 23:57:40 +0000 |
commit | 077b522733ccb812fa3f85e5534782c8dad23d7b (patch) | |
tree | 85f8b7c039b3cc69d2f42e9ffebefa351f4c9a11 /src | |
parent | c1839714a00b09c9d9eadbefd05ec41843d1a289 (diff) | |
download | scintilla-mirror-077b522733ccb812fa3f85e5534782c8dad23d7b.tar.gz |
Don't add extra empty lines with space indentation when performing a
rectangular paste at the end of the document.
Diffstat (limited to 'src')
-rw-r--r-- | src/Editor.cxx | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/Editor.cxx b/src/Editor.cxx index 70f144ff7..41f274529 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -3838,6 +3838,8 @@ void Editor::PasteRectangular(SelectionPosition pos, const char *ptr, int len) { InsertSpace(sel.RangeMain().caret.Position(), sel.RangeMain().caret.VirtualSpace())); int xInsert = XFromPosition(sel.RangeMain().caret); bool prevCr = false; + while ((len > 0) && IsEOLChar(ptr[len-1])) + len--; for (int i = 0; i < len; i++) { if (IsEOLChar(ptr[i])) { if ((ptr[i] == '\r') || (!prevCr)) |