Editor: Animate automatic completed text.

This gives a clear hint that something has changed.
And gets the attention of the author in the case he didn't
expect some kind of automatic brace or quote completion.

Change-Id: I33e383db9a1e797ecb285a407e46671f41be7051
Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com>
This commit is contained in:
David Schulz
2016-04-28 12:51:34 +02:00
parent e108d6fe48
commit d21cd57e13
13 changed files with 101 additions and 17 deletions

View File

@@ -263,6 +263,8 @@ QColor FormatDescription::foreground() const
return m_format.foreground();
} else if (m_id == C_PARENTHESES) {
return QColor(Qt::red);
} else if (m_id == C_AUTOCOMPLETE) {
return QColor(Qt::darkBlue);
}
return m_format.foreground();
}
@@ -279,6 +281,8 @@ QColor FormatDescription::background() const
return QColor(0xb4, 0xee, 0xb4);
} else if (m_id == C_PARENTHESES_MISMATCH) {
return QColor(Qt::magenta);
} else if (m_id == C_AUTOCOMPLETE) {
return QColor(192, 192, 255);
} else if (m_id == C_CURRENT_LINE || m_id == C_SEARCH_SCOPE) {
const QPalette palette = QApplication::palette();
const QColor &fg = palette.color(QPalette::Highlight);