- enhancement: correctly handle auto indents for multi-level embedding complex statements like 'for(...) if (...) printf();

This commit is contained in:
royqh1979 2021-10-30 19:58:13 +08:00
parent 44cf39d8ca
commit 561c83ef58
2 changed files with 3 additions and 1 deletions

View File

@ -1,6 +1,8 @@
Version 0.7.6
- change: don't auto insert a new line when input an enter between '(' and ')' or between '[' and ']' (indent instead)
- enhancement: the line containing '}' will use the indents of the matching '{' line, instead of just unindent one level
- enhancement: the line containing 'public:' / 'private:' / 'protected:' / 'case *:' will use of indents of the surrounding '{' line, instead of just unindent one level
- enhancement: correctly handle auto indents for multi-level embedding complex statements like 'for(...) if (...) printf();
Version 0.7.5
- enhancement: more accurate auto indent calculation

View File

@ -926,7 +926,7 @@ void SynEditCppHighlighter::semiColonProc()
mExtTokenId = ExtTokenKind::SemiColon;
if (mRange.state == RangeState::rsAsm)
mRange.state = RangeState::rsUnknown;
if (mRange.getLastIndent() == sitStatement) {
while (mRange.getLastIndent() == sitStatement) {
popIndents(sitStatement);
}
}