1、头文件包含
    #include <QtGui/QProgressBar>
    #include <QtGui/QProgressDialog>
    #include <QtGui/QMessageBox>
    等类似包含QtGui的包含文件,全部将QtGui取消掉。即
    #include <QProgressBar>
    #include <QProgressDialog>
    #include <QMessageBox>
2、Qt::WFlags 替换为Qt::WindowFlags
3、qInstallMsgHandler 函数废弃
    可修改为: qInstallMessageHandler ,
    MessageOutput 要多加一个参数 : QMessageLogContext& Context
    void  MessageOutput( QtMsgType type, const QMessageLogContext& Context, const QString &sMsg )   
    QtMsgHandler  改为  QtMessageHandler
4、QDesktopServices::storageLocation(QDesktopServices::xxxx) 来获取一些系统目录,
    Qt5则要改成QStandardPaths::writableLocation(QStandardPaths::xxxx)。
5、error: 'UnicodeUTF8' is not a member of 'QApplication'
    原因是:QCoreApplication::UnicodeUTF8已被弃用
    解决方案如下:
    修改
    1
    setText(QApplication::translate("MainWindow", "&Quitar", 0, QApplication::UnicodeUTF8));
     为
    1
    setText(QApplication::translate("MainWindow", "&Quitar", 0);
6、toAscii() 和 fromAscii() 方法已经被舍弃
    可以使用 fromLatin1() 和 toLatin1() 代替
7、nullptr启用,改用为NULL
8、QHBoxLayout启用,可更改为QFrame
9、构建时发生如下错误:
    问题:error: undefined reference to `_imp__glClearColor@16'
    解决办法:这是相关库文件没有链接,在 .pro 文件中加入 openGL相关库即可:
                win32:LIBS += -lOpengl32 \
                                -lglu32 \
                                -lglut

最新文章

  1. 重构Mybatis与Spring集成的SqlSessionFactoryBean(2)
  2. 在SSIS中的不同组件间使用局部临时表
  3. 结构体类型定义(C语言)
  4. codeforces 381 D Alyona and a tree(倍增)(前缀数组)
  5. UISegment
  6. 产品设计敏感度之kindle touch 4
  7. 【Zookeeper学习】Zookeeper-3.4.6安装部署
  8. power desinger 学习笔记&lt;五&gt;
  9. Domain Shutdown Error(JBAS010850)
  10. 项目中出现黄色感叹号 教你去掉Myeclipse的黄色感叹号
  11. vue轮播组件及去掉路由#
  12. 单幅图像的深度学习,对NYU数据集进行划分
  13. vue实战记录(一)- vue实现购物车功能之前提准备
  14. 纯小白入手 vue3.0 CLI - 2.6 - 组件的复用
  15. Vue(三):vuex是什么
  16. PHP简单工厂模式、工厂方法模式和抽象工厂模式
  17. 异常来自 HRESULT:0x80070057 (E_INVALIDARG)
  18. bootstrap-treeview中文API 以及后台JSON数据处理
  19. RedHat yum源配置
  20. WPF进阶之接口(2):IDisposable,ICollectionView

热门文章

  1. BZOJ3212: Pku3468 A Simple Problem with Integers(线段树)
  2. 使用TortoiseGit+码云管理项目代码
  3. Tomcat的最大并发数
  4. hadoop之 安全模式及SafeModeException
  5. Phonegap Android 项目使用Cordova
  6. XiaoMi Interview Log
  7. oracle/ms sql 系统表
  8. yii2 memcache 跨平台交互 键和值不一样
  9. mysql-9索引
  10. 20181123_SQL Server 2008_找出以逗号分隔的字符串中最大的数字