Commit ea8cb476 authored by Leandro Melo's avatar Leandro Melo

Editors: Move auto-completion code out of the editor

This is basically a continuation of the commits which
refactor code out of the base text editor. For instance,
36fa1de4 and
3a684586.

Also removed the doXXXX() forwarding methods.
parent e117f04f
......@@ -48,8 +48,8 @@ CppAutoCompleter::CppAutoCompleter()
CppAutoCompleter::~CppAutoCompleter()
{}
bool CppAutoCompleter::doContextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert) const
bool CppAutoCompleter::contextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert) const
{
QChar ch;
......@@ -66,7 +66,7 @@ bool CppAutoCompleter::doContextAllowsAutoParentheses(const QTextCursor &cursor,
return true;
}
bool CppAutoCompleter::doContextAllowsElectricCharacters(const QTextCursor &cursor) const
bool CppAutoCompleter::contextAllowsElectricCharacters(const QTextCursor &cursor) const
{
const Token tk = SimpleLexer::tokenAt(cursor.block().text(), cursor.positionInBlock(),
BackwardsScanner::previousBlockState(cursor.block()));
......@@ -98,7 +98,7 @@ bool CppAutoCompleter::doContextAllowsElectricCharacters(const QTextCursor &curs
return true;
}
bool CppAutoCompleter::doIsInComment(const QTextCursor &cursor) const
bool CppAutoCompleter::isInComment(const QTextCursor &cursor) const
{
const Token tk = SimpleLexer::tokenAt(cursor.block().text(), cursor.positionInBlock(),
BackwardsScanner::previousBlockState(cursor.block()));
......@@ -122,7 +122,7 @@ bool CppAutoCompleter::doIsInComment(const QTextCursor &cursor) const
return false;
}
QString CppAutoCompleter::doInsertMatchingBrace(const QTextCursor &cursor,
QString CppAutoCompleter::insertMatchingBrace(const QTextCursor &cursor,
const QString &text,
QChar la,
int *skippedChars) const
......@@ -131,7 +131,7 @@ QString CppAutoCompleter::doInsertMatchingBrace(const QTextCursor &cursor,
return m.insertMatchingBrace(cursor, text, la, skippedChars);
}
QString CppAutoCompleter::doInsertParagraphSeparator(const QTextCursor &cursor) const
QString CppAutoCompleter::insertParagraphSeparator(const QTextCursor &cursor) const
{
MatchingText m;
return m.insertParagraphSeparator(cursor);
......
......@@ -41,16 +41,15 @@ public:
CppAutoCompleter();
virtual ~CppAutoCompleter();
private:
virtual bool doContextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert = QString()) const;
virtual bool doContextAllowsElectricCharacters(const QTextCursor &cursor) const;
virtual bool doIsInComment(const QTextCursor &cursor) const;
virtual QString doInsertMatchingBrace(const QTextCursor &cursor,
const QString &text,
QChar la,
int *skippedChars) const;
virtual QString doInsertParagraphSeparator(const QTextCursor &cursor) const;
virtual bool contextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert = QString()) const;
virtual bool contextAllowsElectricCharacters(const QTextCursor &cursor) const;
virtual bool isInComment(const QTextCursor &cursor) const;
virtual QString insertMatchingBrace(const QTextCursor &cursor,
const QString &text,
QChar la,
int *skippedChars) const;
virtual QString insertParagraphSeparator(const QTextCursor &cursor) const;
};
} // Internal
......
......@@ -47,7 +47,7 @@ CppQtStyleIndenter::CppQtStyleIndenter()
CppQtStyleIndenter::~CppQtStyleIndenter()
{}
bool CppQtStyleIndenter::doIsElectricalCharacter(const QChar &ch) const
bool CppQtStyleIndenter::isElectricCharacter(const QChar &ch) const
{
if (ch == QLatin1Char('{') ||
ch == QLatin1Char('}') ||
......@@ -58,10 +58,10 @@ bool CppQtStyleIndenter::doIsElectricalCharacter(const QChar &ch) const
return false;
}
void CppQtStyleIndenter::doIndentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor)
void CppQtStyleIndenter::indentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor)
{
Q_UNUSED(doc)
......@@ -86,10 +86,10 @@ void CppQtStyleIndenter::doIndentBlock(QTextDocument *doc,
ts.indentLine(block, indent + padding, padding);
}
void CppQtStyleIndenter::doIndent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor)
void CppQtStyleIndenter::indent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor)
{
if (cursor.hasSelection()) {
QTextBlock block = doc->findBlock(cursor.selectionStart());
......
......@@ -41,17 +41,16 @@ public:
CppQtStyleIndenter();
virtual ~CppQtStyleIndenter();
private:
virtual bool doIsElectricalCharacter(const QChar &ch) const;
virtual void doIndentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor);
virtual void doIndent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor);
virtual bool isElectricCharacter(const QChar &ch) const;
virtual void indentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor);
virtual void indent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor);
};
} // Internal
......
......@@ -47,8 +47,8 @@ GLSLCompleter::GLSLCompleter()
GLSLCompleter::~GLSLCompleter()
{}
bool GLSLCompleter::doContextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert) const
bool GLSLCompleter::contextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert) const
{
QChar ch;
......@@ -65,7 +65,7 @@ bool GLSLCompleter::doContextAllowsAutoParentheses(const QTextCursor &cursor,
return true;
}
bool GLSLCompleter::doContextAllowsElectricCharacters(const QTextCursor &cursor) const
bool GLSLCompleter::contextAllowsElectricCharacters(const QTextCursor &cursor) const
{
const Token tk = SimpleLexer::tokenAt(cursor.block().text(), cursor.positionInBlock(),
BackwardsScanner::previousBlockState(cursor.block()));
......@@ -97,7 +97,7 @@ bool GLSLCompleter::doContextAllowsElectricCharacters(const QTextCursor &cursor)
return true;
}
bool GLSLCompleter::doIsInComment(const QTextCursor &cursor) const
bool GLSLCompleter::isInComment(const QTextCursor &cursor) const
{
const Token tk = SimpleLexer::tokenAt(cursor.block().text(), cursor.positionInBlock(),
BackwardsScanner::previousBlockState(cursor.block()));
......@@ -121,16 +121,16 @@ bool GLSLCompleter::doIsInComment(const QTextCursor &cursor) const
return false;
}
QString GLSLCompleter::doInsertMatchingBrace(const QTextCursor &cursor,
const QString &text,
QChar la,
int *skippedChars) const
QString GLSLCompleter::insertMatchingBrace(const QTextCursor &cursor,
const QString &text,
QChar la,
int *skippedChars) const
{
MatchingText m;
return m.insertMatchingBrace(cursor, text, la, skippedChars);
}
QString GLSLCompleter::doInsertParagraphSeparator(const QTextCursor &cursor) const
QString GLSLCompleter::insertParagraphSeparator(const QTextCursor &cursor) const
{
MatchingText m;
return m.insertParagraphSeparator(cursor);
......
......@@ -41,16 +41,15 @@ public:
GLSLCompleter();
virtual ~GLSLCompleter();
private:
virtual bool doContextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert = QString()) const;
virtual bool doContextAllowsElectricCharacters(const QTextCursor &cursor) const;
virtual bool doIsInComment(const QTextCursor &cursor) const;
virtual QString doInsertMatchingBrace(const QTextCursor &cursor,
const QString &text,
QChar la,
int *skippedChars) const;
virtual QString doInsertParagraphSeparator(const QTextCursor &cursor) const;
virtual bool contextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert = QString()) const;
virtual bool contextAllowsElectricCharacters(const QTextCursor &cursor) const;
virtual bool isInComment(const QTextCursor &cursor) const;
virtual QString insertMatchingBrace(const QTextCursor &cursor,
const QString &text,
QChar la,
int *skippedChars) const;
virtual QString insertParagraphSeparator(const QTextCursor &cursor) const;
};
} // Internal
......
......@@ -47,7 +47,7 @@ GLSLIndenter::GLSLIndenter()
GLSLIndenter::~GLSLIndenter()
{}
bool GLSLIndenter::doIsElectricalCharacter(const QChar &ch) const
bool GLSLIndenter::isElectricCharacter(const QChar &ch) const
{
if (ch == QLatin1Char('{') ||
ch == QLatin1Char('}') ||
......@@ -58,10 +58,10 @@ bool GLSLIndenter::doIsElectricalCharacter(const QChar &ch) const
return false;
}
void GLSLIndenter::doIndentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor)
void GLSLIndenter::indentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor)
{
Q_UNUSED(doc)
......@@ -86,10 +86,10 @@ void GLSLIndenter::doIndentBlock(QTextDocument *doc,
ts.indentLine(block, indent + padding, padding);
}
void GLSLIndenter::doIndent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor)
void GLSLIndenter::indent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor)
{
if (cursor.hasSelection()) {
QTextBlock block = doc->findBlock(cursor.selectionStart());
......
......@@ -41,17 +41,16 @@ public:
GLSLIndenter();
virtual ~GLSLIndenter();
private:
virtual bool doIsElectricalCharacter(const QChar &ch) const;
virtual void doIndentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor);
virtual void doIndent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor);
virtual bool isElectricCharacter(const QChar &ch) const;
virtual void indentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor);
virtual void indent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor);
};
} // Internal
......
......@@ -143,8 +143,8 @@ AutoCompleter::AutoCompleter()
AutoCompleter::~AutoCompleter()
{}
bool AutoCompleter::doContextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert) const
bool AutoCompleter::contextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert) const
{
QChar ch;
......@@ -200,7 +200,7 @@ bool AutoCompleter::doContextAllowsAutoParentheses(const QTextCursor &cursor,
return true;
}
bool AutoCompleter::doContextAllowsElectricCharacters(const QTextCursor &cursor) const
bool AutoCompleter::contextAllowsElectricCharacters(const QTextCursor &cursor) const
{
Token token = tokenUnderCursor(cursor);
switch (token.kind) {
......@@ -212,15 +212,15 @@ bool AutoCompleter::doContextAllowsElectricCharacters(const QTextCursor &cursor)
}
}
bool AutoCompleter::doIsInComment(const QTextCursor &cursor) const
bool AutoCompleter::isInComment(const QTextCursor &cursor) const
{
return tokenUnderCursor(cursor).is(Token::Comment);
}
QString AutoCompleter::doInsertMatchingBrace(const QTextCursor &cursor,
const QString &text,
QChar,
int *skippedChars) const
QString AutoCompleter::insertMatchingBrace(const QTextCursor &cursor,
const QString &text,
QChar,
int *skippedChars) const
{
if (text.length() != 1)
return QString();
......@@ -268,7 +268,7 @@ QString AutoCompleter::doInsertMatchingBrace(const QTextCursor &cursor,
return QString();
}
QString AutoCompleter::doInsertParagraphSeparator(const QTextCursor &cursor) const
QString AutoCompleter::insertParagraphSeparator(const QTextCursor &cursor) const
{
if (shouldInsertNewline(cursor)) {
QTextCursor cursor = cursor;
......
......@@ -41,16 +41,15 @@ public:
AutoCompleter();
virtual ~AutoCompleter();
private:
virtual bool doContextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert = QString()) const;
virtual bool doContextAllowsElectricCharacters(const QTextCursor &cursor) const;
virtual bool doIsInComment(const QTextCursor &cursor) const;
virtual QString doInsertMatchingBrace(const QTextCursor &tc,
virtual bool contextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert = QString()) const;
virtual bool contextAllowsElectricCharacters(const QTextCursor &cursor) const;
virtual bool isInComment(const QTextCursor &cursor) const;
virtual QString insertMatchingBrace(const QTextCursor &tc,
const QString &text,
QChar la,
int *skippedChars) const;
virtual QString doInsertParagraphSeparator(const QTextCursor &tc) const;
virtual QString insertParagraphSeparator(const QTextCursor &tc) const;
};
} // Internal
......
......@@ -47,7 +47,7 @@ Indenter::Indenter()
Indenter::~Indenter()
{}
bool Indenter::doIsElectricalCharacter(const QChar &ch) const
bool Indenter::isElectricCharacter(const QChar &ch) const
{
if (ch == QLatin1Char('}')
|| ch == QLatin1Char(']')
......@@ -56,10 +56,10 @@ bool Indenter::doIsElectricalCharacter(const QChar &ch) const
return false;
}
void Indenter::doIndentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor)
void Indenter::indentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor)
{
Q_UNUSED(doc)
Q_UNUSED(typedChar)
......
......@@ -41,12 +41,11 @@ public:
Indenter();
virtual ~Indenter();
private:
virtual bool doIsElectricalCharacter(const QChar &ch) const;
virtual void doIndentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor);
virtual bool isElectricCharacter(const QChar &ch) const;
virtual void indentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
TextEditor::BaseTextEditor *editor);
};
} // Internal
......
This diff is collapsed.
......@@ -47,30 +47,45 @@ public:
AutoCompleter();
virtual ~AutoCompleter();
bool contextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert = QString()) const;
bool contextAllowsElectricCharacters(const QTextCursor &cursor) const;
void setAutoParenthesesEnabled(bool b);
bool isAutoParenthesesEnabled() const;
void setSurroundWithEnabled(bool b);
bool isSurroundWithEnabled() const;
// Returns the text to complete at the cursor position, or an empty string
virtual QString autoComplete(QTextCursor &cursor, const QString &text) const;
// Handles backspace. When returning true, backspace processing is stopped
virtual bool autoBackspace(QTextCursor &cursor);
// Hook to insert special characters on enter. Returns the number of extra blocks inserted.
virtual int paragraphSeparatorAboutToBeInserted(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.
bool isInComment(const QTextCursor &cursor) const;
virtual bool isInComment(const QTextCursor &cursor) const;
virtual QString insertMatchingBrace(const QTextCursor &cursor, const
QString &text,
QChar la,
int *skippedChars) const;
QString insertMatchingBrace(const QTextCursor &cursor, const
QString &text,
QChar la,
int *skippedChars) const;
// Returns the text that needs to be inserted
QString insertParagraphSeparator(const QTextCursor &cursor) const;
virtual QString insertParagraphSeparator(const QTextCursor &cursor) const;
protected:
static void countBracket(QChar open, QChar close, QChar c, int *errors, int *stillopen);
static void countBrackets(QTextCursor cursor, int from, int end, QChar open, QChar close,
int *errors, int *stillopen);
private:
virtual bool doContextAllowsAutoParentheses(const QTextCursor &cursor,
const QString &textToInsert = QString()) const;
virtual bool doContextAllowsElectricCharacters(const QTextCursor &cursor) const;
virtual bool doIsInComment(const QTextCursor &cursor) const;
virtual QString doInsertMatchingBrace(const QTextCursor &cursor,
const QString &text,
QChar la,
int *skippedChars) const;
virtual QString doInsertParagraphSeparator(const QTextCursor &cursor) const;
mutable bool m_allowSkippingOfBlockEnd;
bool m_surroundWithEnabled;
bool m_autoParenthesesEnabled;
};
} // TextEditor
......
This diff is collapsed.
......@@ -168,12 +168,6 @@ public:
void setParenthesesMatchingEnabled(bool b);
bool isParenthesesMatchingEnabled() const;
void setAutoParenthesesEnabled(bool b);
bool isAutoParenthesesEnabled() const;
void setSurroundWithEnabled(bool b);
bool isSurroundWithEnabled() const;
void setHighlightCurrentLine(bool b);
bool highlightCurrentLine() const;
......@@ -424,24 +418,10 @@ protected:
void dragEnterEvent(QDragEnterEvent *e);
public:
// Returns the text to complete at the cursor position, or an empty string
virtual QString autoComplete(QTextCursor &cursor, const QString &text) const;
// Handles backspace. When returning true, backspace processing is stopped
virtual bool autoBackspace(QTextCursor &cursor);
// Hook to insert special characters on enter. Returns the number of extra blocks inserted.
virtual int paragraphSeparatorAboutToBeInserted(QTextCursor &cursor);
void indentInsertedText(const QTextCursor &tc);
void indent(QTextDocument *doc, const QTextCursor &cursor, QChar typedChar);
void reindent(QTextDocument *doc, const QTextCursor &cursor);
protected:
static void countBracket(QChar open, QChar close, QChar c, int *errors, int *stillopen);
static void countBrackets(QTextCursor cursor, int from, int end, QChar open, QChar close,
int *errors, int *stillopen);
public:
struct Link
{
Link(const QString &fileName = QString(),
......
......@@ -180,7 +180,6 @@ public:
BaseTextEditor *q;
bool m_contentsChanged;
bool m_lastCursorChangeWasInteresting;
bool m_allowSkippingOfBlockEnd;
QList<QTextEdit::ExtraSelection> m_syntaxHighlighterSelections;
QTextEdit::ExtraSelection m_lineSelection;
......@@ -191,8 +190,6 @@ public:
QString m_displayName;
bool m_parenthesesMatchingEnabled;
bool m_autoParenthesesEnabled;
bool m_surroundWithEnabled;
QTimer *m_updateTimer;
Utils::ChangeSet m_changeSet;
......
......@@ -39,38 +39,12 @@ Indenter::Indenter()
Indenter::~Indenter()
{}
bool Indenter::isElectricCharacter(const QChar &ch) const
{
return doIsElectricalCharacter(ch);
}
void Indenter::indentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
BaseTextEditor *editor)
{
doIndentBlock(doc, block, typedChar, editor);
}
void Indenter::indent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
BaseTextEditor *editor)
{
doIndent(doc, cursor, typedChar, editor);
}
void Indenter::reindent(QTextDocument *doc, const QTextCursor &cursor, BaseTextEditor *editor)
{
doReindent(doc, cursor, editor);
}
bool Indenter::doIsElectricalCharacter(const QChar &) const
bool Indenter::isElectricCharacter(const QChar &) const
{
return false;
}
void Indenter::doIndentBlock(QTextDocument *doc,
void Indenter::indentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
BaseTextEditor *editor)
......@@ -81,7 +55,10 @@ void Indenter::doIndentBlock(QTextDocument *doc,
Q_UNUSED(editor);
}
void Indenter::doIndent(QTextDocument *doc, const QTextCursor &cursor, const QChar &typedChar, BaseTextEditor *editor)
void Indenter::indent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
BaseTextEditor *editor)
{
if (cursor.hasSelection()) {
QTextBlock block = doc->findBlock(cursor.selectionStart());
......@@ -95,7 +72,7 @@ void Indenter::doIndent(QTextDocument *doc, const QTextCursor &cursor, const QCh
}
}
void Indenter::doReindent(QTextDocument *doc, const QTextCursor &cursor, BaseTextEditor *editor)
void Indenter::reindent(QTextDocument *doc, const QTextCursor &cursor, BaseTextEditor *editor)
{
if (cursor.hasSelection()) {
QTextBlock block = doc->findBlock(cursor.selectionStart());
......
......@@ -51,32 +51,23 @@ public:
virtual ~Indenter();
// Returns true if key triggers an indent.
bool isElectricCharacter(const QChar &ch) const;
virtual bool isElectricCharacter(const QChar &ch) const;
// Indent a text block based on previous line. Default does nothing
void indentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
BaseTextEditor *editor);
virtual void indentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
BaseTextEditor *editor);
// Indent at cursor. Calls indentBlock for selection or current line.
void indent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
BaseTextEditor *editor);
virtual void indent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
BaseTextEditor *editor);
// Reindent at cursor. Selection will be adjusted according to the indentation
// change of the first block.
void reindent(QTextDocument *doc, const QTextCursor &cursor, BaseTextEditor *editor);
private:
virtual bool doIsElectricalCharacter(const QChar &ch) const;
virtual void doIndentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
BaseTextEditor *editor);
virtual void doIndent(QTextDocument *doc,
const QTextCursor &cursor,
const QChar &typedChar,
BaseTextEditor *editor);
virtual void doReindent(QTextDocument *doc, const QTextCursor &cursor, BaseTextEditor *editor);
virtual void reindent(QTextDocument *doc, const QTextCursor &cursor, BaseTextEditor *editor);
};
} // namespace TextEditor
......
......@@ -60,10 +60,10 @@ NormalIndenter::~NormalIndenter()
// for additional block being inserted. It might be possible
// to do in 2 steps (indenting/wrapping)}
//
void NormalIndenter::doIndentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
BaseTextEditor *editor)
void NormalIndenter::indentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
BaseTextEditor *editor)
{
Q_UNUSED(typedChar)
......
......@@ -40,11 +40,10 @@ public:
NormalIndenter();
virtual ~NormalIndenter();
private:
virtual void doIndentBlock(QTextDocument *doc,
const QTextBlock &block,
const QChar &typedChar,
BaseTextEditor *editor);