Commit 7400557f authored by Leandro Melo's avatar Leandro Melo

Fix in Utils::unCommentSelection to consider initial whites spaces when...

Fix in Utils::unCommentSelection to consider initial whites spaces when there's no selection and single line comment style.
parent e7ddd2b8
......@@ -193,6 +193,15 @@ void Utils::unCommentSelection(QPlainTextEdit *edit, const CommentDefinition &de
start = startBlock.position();
end = endBlock.position() + endBlock.length() - 1;
if (doMultiLineStyleUncomment) {
int offset = 0;
text = startBlock.text();
const int length = text.length();
while (offset < length && text.at(offset).isSpace())
++offset;
start += offset;
}
}
if (doMultiLineStyleUncomment) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment