OneLevelXmlOpr/main.cpp

28 lines
509 B
C++
Raw Normal View History

2024-05-15 08:34:54 +08:00
#include <QApplication>
#include <clocale>
2024-05-15 08:34:54 +08:00
#include "MainWidget.h"
2024-05-15 08:34:54 +08:00
int main(int argc, char *argv[])
{
setlocale(LC_ALL, ".utf-8");
2024-05-15 08:34:54 +08:00
QApplication a(argc, argv);
#ifdef _WIN32
2024-07-28 10:27:54 +08:00
QFont font("Microsoft YaHei", 9);
a.setFont(font);
2024-09-15 15:22:06 +08:00
//a.setStyle("fusion");
a.setStyle("windows");
#endif
#if (QT_VERSION < QT_VERSION_CHECK(6, 0, 0))
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
#endif
2024-05-15 08:34:54 +08:00
MainWidget w;
w.set_work_exe(argv[0]);
2024-05-15 08:34:54 +08:00
w.show();
return a.exec();
}