forked from qt-creator/qt-creator
Avoid triggering indent for electric characters in comments and strings
In comments and strings, electric characters have no syntactical significance and the unnecessary automatic reindent can be annoying. Reviewed-by: Erik Verbruggen
This commit is contained in:
@@ -403,6 +403,7 @@ protected:
|
||||
virtual void reindent(QTextDocument *doc, const QTextCursor &cursor);
|
||||
|
||||
virtual bool contextAllowsAutoParentheses(const QTextCursor &cursor, const QString &textToInsert = QString()) const;
|
||||
virtual bool contextAllowsElectricCharacters(const QTextCursor &cursor) const;
|
||||
|
||||
// Returns true if the cursor is inside a comment.
|
||||
virtual bool isInComment(const QTextCursor &cursor) const;
|
||||
|
||||
Reference in New Issue
Block a user