diff --git a/libs/qsynedit/qsynedit/qsynedit.cpp b/libs/qsynedit/qsynedit/qsynedit.cpp index d4f43bf9..aef07287 100644 --- a/libs/qsynedit/qsynedit/qsynedit.cpp +++ b/libs/qsynedit/qsynedit/qsynedit.cpp @@ -1620,13 +1620,17 @@ int QSynEdit::calcIndentSpaces(int line, const QString& lineText, bool addIndent SyntaxState rangeAfterFirstToken = mSyntaxer->getState(); QString firstToken = mSyntaxer->getToken(); PTokenAttribute attr = mSyntaxer->getTokenAttribute(); - if (attr->tokenType() == TokenType::Keyword + if ( + ( (attr->tokenType() == TokenType::Keyword + && ( + firstToken == "public" || firstToken == "private" + || firstToken == "protected" || firstToken == "case" + || firstToken == "default" + ) + ) + || (attr->tokenType() == TokenType::Identifier)) && lineText.endsWith(':') - && ( - firstToken == "public" || firstToken == "private" - || firstToken == "protected" || firstToken == "case" - || firstToken == "default" - )) { + ) { // public: private: protecte: case: should indents like it's parent statement mSyntaxer->setState(rangePreceeding); mSyntaxer->setLine("}",line-1); diff --git a/libs/qsynedit/qsynedit/syntaxer/asm.cpp b/libs/qsynedit/qsynedit/syntaxer/asm.cpp index a3a41011..4e476fa9 100644 --- a/libs/qsynedit/qsynedit/syntaxer/asm.cpp +++ b/libs/qsynedit/qsynedit/syntaxer/asm.cpp @@ -98,6 +98,7 @@ const QSet ASMSyntaxer::Directives { "section","global","extern","segment", "db","dw","dd","dq","dt","do","dy","dz", "resb","resw","resd","resq","rest","reso","resy","resz", + "equ","times","word","dword","byte","tword" };