forked from qt-creator/qt-creator
ClangFormat: Fix preview update
Fixes: QTCREATORBUG-30089 Change-Id: Id89e8b2ee0439c5235755256e8410f42ad94b432 Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
@@ -49,6 +49,8 @@ public:
|
||||
|
||||
const clang::format::FormatStyle &styleForFile() const;
|
||||
|
||||
void setOverriddenPreferences(TextEditor::ICodeStylePreferences *preferences);
|
||||
|
||||
protected:
|
||||
virtual bool formatCodeInsteadOfIndent() const { return false; }
|
||||
virtual bool formatWhileTyping() const { return false; }
|
||||
@@ -84,6 +86,9 @@ private:
|
||||
};
|
||||
|
||||
mutable CachedStyle m_cachedStyle;
|
||||
|
||||
clang::format::FormatStyle overrideStyle(const Utils::FilePath &fileName) const;
|
||||
TextEditor::ICodeStylePreferences *m_overriddenPreferences = nullptr;
|
||||
};
|
||||
|
||||
} // namespace ClangFormat
|
||||
|
||||
Reference in New Issue
Block a user