界面完成
This commit is contained in:
7
main.cpp
7
main.cpp
@ -1,11 +1,14 @@
|
||||
#include "mainwindow.h"
|
||||
|
||||
#include <QApplication>
|
||||
|
||||
#include <Windows.h>
|
||||
double scale;
|
||||
int main(int argc, char *argv[])
|
||||
{
|
||||
QCoreApplication::setAttribute(Qt::AA_EnableHighDpiScaling);
|
||||
QApplication a(argc, argv);
|
||||
HDC hdc = GetDC(NULL);
|
||||
scale = GetDeviceCaps(hdc, LOGPIXELSX)/96;
|
||||
ReleaseDC(NULL,hdc);
|
||||
MainWindow w;
|
||||
w.show();
|
||||
return a.exec();
|
||||
|
Reference in New Issue
Block a user