GH-2101 select everything when editing instance names

This commit is contained in:
Petr Mrázek 2018-11-23 21:47:23 +01:00
parent 54e857a7f5
commit e8c382bede

View File

@ -389,6 +389,7 @@ void ListViewDelegate::setEditorData(QWidget* editor, const QModelIndex& index)
QTextEdit * realeditor = qobject_cast<NoReturnTextEdit *>(editor);
realeditor->setAlignment(Qt::AlignHCenter | Qt::AlignTop);
realeditor->append(text);
realeditor->selectAll();
realeditor->document()->clearUndoRedoStacks();
}