![](https://img-blog.csdnimg.cn/20201014180756916.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
QT
bug狂人
去看代码吧。
展开
-
QT CmakeLists配置python
无法打开文件“python36_d.lib”原创 2023-10-11 10:08:54 · 256 阅读 · 0 评论 -
QtCreator CMakeLists.txt添加模块(Modules)
CMakeLists.txt添加模块(Modules)原创 2023-09-07 10:25:59 · 533 阅读 · 0 评论 -
QFtp集成
QFtp原创 2023-01-30 22:50:37 · 272 阅读 · 0 评论 -
QT字体阴影
.h#pragma once#include <QLabel>class FontQlabel : public QLabel{ Q_OBJECTpublic: FontQlabel(QWidget *parent); ~FontQlabel();protected: void paintEvent(QPaintEvent *) override;};.cpp#include "FontQlabel.h"#include <QPainter&原创 2022-05-05 13:44:04 · 1119 阅读 · 0 评论 -
QComboBox自动展开
//仅此一句ui.comboBox->showPopup();原创 2022-04-29 09:48:59 · 829 阅读 · 0 评论 -
QcomboBox可显示不可选中
ui.comboBox_com_list->clear(); int falseCnt = 0; ui.comboBox_com_list->addItems(nameList); for (int i = 0; i < cam_count; i++) { QModelIndex index = ui.comboBox_com_list->model()->index(i, 0); if (camSignal[i] == false) { QVa.原创 2022-03-25 15:18:06 · 1120 阅读 · 0 评论 -
QLlinEdit自动转大写
void UIFloatConsole::on_lineEdit_number_textEdited(const QString &arg1){ QString str = arg1.toUpper(); ui.lineEdit_number->setText(str);}监听textEdited事件,获取text后转大写然后set。原创 2022-03-03 09:29:50 · 943 阅读 · 2 评论 -
QT 车牌号正则验证
/** * 判断是否合法车牌号 * @name isCarLicense * @param license 车牌号 * @return bool */bool CarLicense::isCarLicense(QString license){ //参数判断 if (license.isEmpty()) { return false; } int pos = 0; //匹配民用车牌和使馆车牌 //判断标准 //1.第一位为汉子省份缩写 //2.第二位为大写字.原创 2022-02-11 10:48:40 · 404 阅读 · 0 评论 -
qudpsocket设置缓冲区大小
socket_udp = new QUdpSocket;socket_udp->setReadBufferSize(16*1024*1024);原创 2021-10-09 13:44:07 · 2774 阅读 · 3 评论 -
vs qt程序自动拷贝关联qt库
win+R输入cmd。先拖拽Qt\Qt5.12.6\5.12.6\msvc2017_64\bin\windeployqt.exe;空格;再拖拽你的exe;会自动把exe需要的dll拷贝过来;原创 2021-08-18 18:00:02 · 160 阅读 · 0 评论 -
QT 信号槽 lambda
QCheckBox checkBox; connect(&checkBox, &QCheckBox::clicked, [this] { this->savestate[i] = i; emit this->slot_check_btn(i); });connect(&checkBox, static_cast<void(QCheckBox ::*)(bool b)>(&QCheckBox::clicked), [=](boo.原创 2021-08-09 13:28:18 · 723 阅读 · 0 评论 -
ERROR running qmake
1>Reading Qt configuration (D:/SoftWare/QT5.9.3/5.9.3/msvc2017_64/bin/qmake)1>GHViewerDetect.vcxproj : error : ERROR running qmake1>GHViewerDetect.vcxproj : error : qmake: (D:/SoftWare/QT5.9.3/5.9.3/msvc2017_64/bin/qmake)1>GHViewerDetect.vcx原创 2021-08-04 09:58:47 · 3671 阅读 · 1 评论 -
Basler相机QT代码vs
MainWindow.h/********************************************** 说明:Basler相机主界面。* 修改日期:20210625* 作者:mazs* 邮箱:mzsapi@163.com**********************************************/#ifndef _MAIN_WINDOW_H_#define _MAIN_WINDOW_H_#include <QtWidgets/QW原创 2021-06-25 11:00:21 · 621 阅读 · 0 评论 -
ui_.h(12,10): fatal error C1083: 无法打开包括文件: “.h”: No such file or directory
原创 2021-06-04 16:06:44 · 525 阅读 · 0 评论 -
QT添加自定义控件
创建空的.h和.cpp文件原创 2020-07-31 20:49:02 · 321 阅读 · 0 评论 -
QT 自定义槽添加方式
第一种:鼠标悬浮控件右键#ifndef MCOMBOBOX_H#define MCOMBOBOX_H#include <QComboBox>class MComboBox : public QComboBox{ Q_OBJECTpublic: explicit MComboBox(QWidget *parent = 0); ~MComboBox();protected: virtual void mousePressEvent(原创 2020-07-31 20:17:55 · 1003 阅读 · 0 评论 -
QT Failure to find: XXX.ui
打开项目.pro文件,修改FORMS。原创 2020-07-23 14:59:21 · 2682 阅读 · 0 评论 -
QT connect无效分析
connect(objectclass, SIGNAL(classfun()), this, SLOT(thisfun()));注意:emitclassfun();的objectclass对象是不是同一个。原创 2020-06-05 11:25:09 · 1896 阅读 · 0 评论 -
QT控件定位防止漂移
//项目中有的窗体不定位会超出屏幕,具体原因不详。const QRect qr = parent->geometry();this->setGeometry(qr.left(), qr.top(), 600, 420);原创 2018-09-29 10:13:18 · 367 阅读 · 0 评论 -
QT进度条QProgressBar按比例展示
进度条样式代码,可以根据自己的需求修改比例。下面是展示代码;QString QparagraphDlg::setParagraphDlg(){QString strStyle = "";QString paragraph1End;QString paragraph2Str;QString paragraph2End;QString paragraph3Str;d...原创 2018-04-08 16:14:09 · 3215 阅读 · 0 评论