2018-04-10 07:59:20 +00:00
|
|
|
#include <QTextEdit>
|
|
|
|
#include <QVBoxLayout>
|
2018-05-10 09:16:22 +00:00
|
|
|
#include <QOpenGLFunctions>
|
2018-04-10 07:59:20 +00:00
|
|
|
#include "aboutwidget.h"
|
2018-04-11 08:34:51 +00:00
|
|
|
#include "version.h"
|
2018-10-25 00:19:38 +00:00
|
|
|
#include "util.h"
|
2018-04-10 07:59:20 +00:00
|
|
|
|
|
|
|
AboutWidget::AboutWidget()
|
|
|
|
{
|
|
|
|
QTextEdit *versionInfoLabel = new QTextEdit;
|
2018-09-23 01:02:08 +00:00
|
|
|
versionInfoLabel->setText(QString("%1 %2 (version: %3 build: %4 %5)\nopengl: %6 shader: %7 core: %8").arg(APP_NAME).arg(APP_HUMAN_VER).arg(APP_VER).arg(__DATE__).arg(__TIME__).arg((char *)glGetString(GL_VERSION)).arg((char *)glGetString(GL_SHADING_LANGUAGE_VERSION)).arg(QSurfaceFormat::defaultFormat().profile() == QSurfaceFormat::CoreProfile ? "true" : "false"));
|
2018-04-10 07:59:20 +00:00
|
|
|
versionInfoLabel->setReadOnly(true);
|
|
|
|
|
|
|
|
QVBoxLayout *mainLayout = new QVBoxLayout;
|
|
|
|
mainLayout->addWidget(versionInfoLabel);
|
|
|
|
|
|
|
|
setLayout(mainLayout);
|
|
|
|
setFixedSize(QSize(350, 75));
|
|
|
|
|
2018-09-21 07:10:18 +00:00
|
|
|
setWindowTitle(unifiedWindowTitle(tr("About")));
|
2018-04-10 07:59:20 +00:00
|
|
|
}
|