摘要: 1、代码 #ifdef _WIN64 qDebug()<<64; #else qDebug()<<32; #endif 2、注意 _WIN64只有在64位程序上才被定义; _WIN32在64和32位程序上都会被定义 阅读全文
posted @ 2022-05-17 21:38 萧海~ 阅读(250) 评论(0) 推荐(0) 编辑
摘要: 不好理解 class Solution { public: int countSubstrings(string s) { int n = s.size(), sum = 0; for(int i = 0; i < n*2-1; i++) { int l = i / 2, r = i/2 + i%2 阅读全文
posted @ 2022-05-17 16:14 萧海~ 阅读(24) 评论(0) 推荐(0) 编辑
摘要: 原文:https://beondxin.blog.csdn.net/article/details/98480663 临时有需求写些小的任务,比如文件流操作,图片加水印等完成快速部署,或者比较大的项目,编译速度过慢,这时就需要设置预编译。建完新工程实现快速部署和编译。 qt使用预编译只需要在.pro 阅读全文
posted @ 2022-05-17 15:56 萧海~ 阅读(172) 评论(0) 推荐(0) 编辑
摘要: 原文:https://beondxin.blog.csdn.net/article/details/100173606 看到一个不错的文字和图片对应起来的方式,记录下 给每个item传入QtUserRole item->setData(QtUserRole, i.key()); 根据 item->d 阅读全文
posted @ 2022-05-17 15:48 萧海~ 阅读(150) 评论(0) 推荐(0) 编辑
摘要: 原文:https://editor.csdn.net/md?articleId=124823144 图像处理一般都是在opencv/vtk/itk/halcon里做的,qt用来显示 偶尔有很简单图像操作小需求,调用第三方库很麻烦,我这里记录下自己每次有需要临时写的 单纯qt对像素的操作简单的图像处理 阅读全文
posted @ 2022-05-17 15:46 萧海~ 阅读(261) 评论(0) 推荐(0) 编辑
摘要: https://github.com/Greedysky/TTKWidgetTools 研究网上别人代码,看到一个可能以后会用的功能 弹出一个label 过段时间自动淡淡退出 先自定义一个label // 设置背景 setWindowFlags(Qt::Window | Qt::FramelessW 阅读全文
posted @ 2022-05-17 15:44 萧海~ 阅读(174) 评论(0) 推荐(0) 编辑