forked from qt-creator/qt-creator
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:
@@ -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;
|
||||
|
||||
Reference in New Issue
Block a user