Generic highlighter: Indentation based code folding.

This commit is contained in:
Leandro Melo
2010-06-21 13:37:53 +02:00
parent ec249304e6
commit 15faf23e07
11 changed files with 164 additions and 31 deletions

View File

@@ -153,6 +153,17 @@ void PlainTextEditor::setFontSettings(const FontSettings &fs)
}
}
void PlainTextEditor::setTabSettings(const TextEditor::TabSettings &ts)
{
BaseTextEditor::setTabSettings(ts);
if (baseTextDocument()->syntaxHighlighter()) {
Highlighter *highlighter =
static_cast<Highlighter *>(baseTextDocument()->syntaxHighlighter());
highlighter->setTabSettings(ts);
}
}
void PlainTextEditor::fileChanged()
{
configure(Core::ICore::instance()->mimeDatabase()->findByFile(file()->fileName()));