diff options
Diffstat (limited to 'src/Editor.cxx')
| -rw-r--r-- | src/Editor.cxx | 6 | 
1 files changed, 5 insertions, 1 deletions
| diff --git a/src/Editor.cxx b/src/Editor.cxx index e6a1637f9..fd21e47bb 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -1002,6 +1002,10 @@ void Editor::VerticalCentreCaret() {  void Editor::MoveSelectedLines(int lineDelta) { +	if (sel.IsRectangular()) { +		return; +	} +  	// if selection doesn't start at the beginning of the line, set the new start  	Sci::Position selectionStart = SelectionStart().Position();  	const Sci::Line startLine = pdoc->SciLineFromPosition(selectionStart); @@ -1054,7 +1058,7 @@ void Editor::MoveSelectedLines(int lineDelta) {  		pdoc->InsertString(pdoc->Length(), eol, strlen(eol));  	GoToLine(currentLine + lineDelta); -	selectionLength = pdoc->InsertString(CurrentPosition(), selectedText.Data(), selectionLength); +	selectionLength = pdoc->InsertString(CurrentPosition(), selectedText.Data(), selectedText.Length());  	if (appendEol) {  		const Sci::Position lengthInserted = pdoc->InsertString(CurrentPosition() + selectionLength, eol, strlen(eol));  		selectionLength += lengthInserted; | 
