摘要: //线程函数后台运行 ,中不能操作图形类mythread.h文件 #ifndef MYTHREAD_H #define MYTHREAD_H #include <QObject> class mythread : public QObject { Q_OBJECT //使用信号和槽必须使用这个宏 p 阅读全文
posted @ 2021-10-12 19:16 A_Powered 阅读(40) 评论(0) 推荐(0) 编辑
摘要: #include <QDebug> #define cout qDebug() <<"[" <<FILE <<":" <<LINE <<"]" 阅读全文
posted @ 2021-10-12 17:33 A_Powered 阅读(139) 评论(0) 推荐(0) 编辑
摘要: 恢复内容开始 null 恢复内容结束 阅读全文
posted @ 2021-10-11 21:02 A_Powered 阅读(18) 评论(0) 推荐(0) 编辑
摘要: https://blog.csdn.net/qq319923400/article/details/80149367 阅读全文
posted @ 2021-10-08 12:53 A_Powered 阅读(9) 评论(0) 推荐(0) 编辑
摘要: 改成release版本 进行编译 编译成功后,找到对应文件夹 复制出.exe文件 创建文件夹。 在cmd中找到路径,shift加右键,在此处打开默认窗口 默认的安装QT中windeployqt.exe 在cmd中的文件路径下.windeployqt changjiankongjian.exe (wi 阅读全文
posted @ 2021-10-05 12:24 A_Powered 阅读(27) 评论(0) 推荐(0) 编辑
摘要: QPushButton类 设置禁用状态 startBtn->setEnabled(false); 阅读全文
posted @ 2021-10-05 12:02 A_Powered 阅读(29) 评论(0) 推荐(0) 编辑
摘要: QSound类 需要在.pro文件中加入这个模块 QSound Class The QSound class provides a method to play .wav sound files. More... Header: #include <QSound> qmake: QT += mult 阅读全文
posted @ 2021-10-05 12:01 A_Powered 阅读(139) 评论(0) 推荐(0) 编辑
摘要: 在按钮上又覆盖了label时 这时点击按钮是起不到任何作用的 我们就需要添加个鼠标穿透事件 label->setAttribute(Qt::WA_TransparentForMouseEvents); //51号属性 这时,我们才可以点击按钮了 阅读全文
posted @ 2021-10-04 18:00 A_Powered 阅读(740) 评论(0) 推荐(0) 编辑
摘要: 1.首先添加新文件.cpp,.h .h中,明确继承类 .cpp中 画家形式添加图片, 动画效果,使用QPropertyAnimation类 阅读全文
posted @ 2021-10-04 15:29 A_Powered 阅读(51) 评论(0) 推荐(0) 编辑
摘要: QTimer类 //延时时间, 作用对象,lamda表达式QTimer::singleShot(500,this,[=](){ //进入下一个场景中 this->hide(); //显示关卡场景 chooseS->show(); }); 阅读全文
posted @ 2021-10-04 15:24 A_Powered 阅读(849) 评论(0) 推荐(0) 编辑