Help: Small improvements for System Info dialog

1) Make the font non-proportional, since qtDiag's output is formatted
with spaces
2) Make the dialog a window with maximize buttons
3) Fix the formatting for unloaded plugins

Change-Id: I911871b1ffc9dceebcbb04f544cc6d580b95c54e
Reviewed-by: Eike Ziller <eike.ziller@qt.io>
This commit is contained in:
Alessandro Portale
2016-09-28 10:57:21 +02:00
parent 615ace36d5
commit 40d7399755
2 changed files with 6 additions and 1 deletions

View File

@@ -675,6 +675,7 @@ void HelpPlugin::slotSystemInformation()
{
auto dialog = new DialogClosingOnEscape(ICore::dialogParent());
dialog->setAttribute(Qt::WA_DeleteOnClose);
dialog->setWindowFlags(Qt::Window);
dialog->setModal(true);
dialog->setWindowTitle(tr("System Information"));
auto layout = new QVBoxLayout;
@@ -684,6 +685,10 @@ void HelpPlugin::slotSystemInformation()
layout->addWidget(intro);
const QString text = "{noformat}\n" + ICore::systemInformation() + "\n{noformat}";
auto info = new QPlainTextEdit;
QFont font = info->font();
font.setFamily("Courier");
font.setStyleHint(QFont::TypeWriter);
info->setFont(font);
info->setPlainText(text);
layout->addWidget(info);
auto buttonBox = new QDialogButtonBox;