特大喜讯,本项目开本Qt从5.10升级到5.13版本了,编译也将使用64位的MinGW编译了。在新版本里面也将会有很多新的问题出现了,比如,tabWidget里面的tabBar,需要包含头文件才能使用了。
目前最新的就是我获取屏幕分辨率的问题,在旧版中,获取屏幕分辨率代码如下
QDesktopWidget *desktopwidget = QApplication::desktop(); QRect screenRect = desktopwidget->screenGeometry();
那么在最新的Qt 5.13中,有了新的方法
QScreen *screen = QGuiApplication::primaryScreen(); QRect screenRect = screen->availableGeometry();
在最新的方法中,需要包含头文件QScreen
#include <QScreen>

