Commit c1ff105a authored by Daniel Teske's avatar Daniel Teske
Browse files

BaseTextEditWidget: Forward everything with ControlModifier to QPTE



Task-number: QTCREATORBUG-11137
Change-Id: Icd1bd55cb8bb3087667b01e18b6774987971601b
Reviewed-by: default avatarEike Ziller <eike.ziller@digia.com>
parent 06f35cbb
......@@ -1805,7 +1805,8 @@ void BaseTextEditorWidget::keyPressEvent(QKeyEvent *e)
return;
}
if (ro || e->text().isEmpty() || !e->text().at(0).isPrint()) {
if (ro || e->text().isEmpty() || !e->text().at(0).isPrint()
|| (e->modifiers() & (Qt::ControlModifier|Qt::AltModifier)) == Qt::ControlModifier) {
if (!cursorMoveKeyEvent(e)) {
QTextCursor cursor = textCursor();
bool cursorWithinSnippet = false;
......@@ -1823,7 +1824,7 @@ void BaseTextEditorWidget::keyPressEvent(QKeyEvent *e)
d->m_snippetOverlay->updateEquivalentSelections(textCursor());
}
}
} else if ((e->modifiers() & (Qt::ControlModifier|Qt::AltModifier)) != Qt::ControlModifier){
} else {
QTextCursor cursor = textCursor();
QString text = e->text();
const QString &autoText = d->m_autoCompleter->autoComplete(cursor, text);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment