Commit 3080d0d9 authored by BogDan Vatra's avatar BogDan Vatra

Make the output window readonly, but still keyboard friendly

  There is no point to change the application output content most
probably it was enable to allow text selection using the keyboard.

  This change is needed to enable output filters, which can't use the
existing content from the output windows because they might be already
filtered.

Change-Id: Ia272143a3a0b085544ee9cd550a4ad4800e3f4dd
Reviewed-by: Eike Ziller's avatarEike Ziller <eike.ziller@qt.io>
Reviewed-by: Vikas Pachdha's avatarVikas Pachdha <vikas.pachdha@qt.io>
Reviewed-by: Ulf Hermann's avatarUlf Hermann <ulf.hermann@qt.io>
parent b15a0eb9
......@@ -68,6 +68,8 @@ QPlainTextEdit *OutputFormatter::plainTextEdit() const
void OutputFormatter::setPlainTextEdit(QPlainTextEdit *plainText)
{
plainText->setReadOnly(true);
plainText->setTextInteractionFlags(plainText->textInteractionFlags() | Qt::TextSelectableByKeyboard);
d->plainTextEdit = plainText;
d->cursor = plainText ? plainText->textCursor() : QTextCursor();
initFormats();
......
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