- 博客(7)
- 收藏
- 关注
转载 Qt-菜单栏
[cpp] view plaincopyprint? //.h #include include QVBoxLayout* layout; QMenuBar* menuBar; QAction* actionNew; //.cpp layout = new QVBoxLayout(this); menuBar = new QMenuBar(this); menuBar->setG
2013-09-25 10:39:17
1045
转载 Qt-QStringList
QStringList类提供了一个字符串列表 从QList 继承而来,它提供快速索引为基础的接入以及快速插入和清除 其成员函数用于操作这个字符串列表如 append(),insert(), replace(), removeAll(), removeAt(), removeFirst(), removeLast(), and removeOne()等 1. 增加字符串
2013-09-14 13:30:02
691
原创 Qt-exec()
MyDialog dialog; dialog.exec(); 非模式对话框dialog.show()会一闪而过,而dialog.exec()会显示对话框,并进入消息循环等待响应
2013-09-12 01:30:50
731
原创 qDebug使用方法
首先在头文件中包含#include 在需要使用的地方插入: qDebug("x: %d",x); 输出结果: x: 0 注: %a,%A 读入一个浮点值(仅C99有效) %c 读入一个字符 %d 读入十进制整数 %i 读入十进制,八进制,十六进制整数 %o 读入八进制整数 %x,%X 读入十六进
2013-09-11 12:38:29
3380
原创 Qt-配置调试器 None of the debugger engines
qt creator中调试状态运行程序时出现:None of the debugger engines "Gdb engine, Cdb engine capable of debugging binaries of the type "x86-windows-msys-pe-32bit"提示信息。 原因:使用自动检测到的编译工具时,默认没有配置调试器。 解决办法:Tools->Opt
2013-09-11 12:18:47
2425
原创 Qt-显示中文
QTextCodec::setCodecForTr(QTextCodec::codecForLocale()); instance: QDialog *dd = new QDialog(); QTextCodec::setCodecForTr(QTextCodec::codecForLocale()); dd->setWindowTitle(QObject::t
2013-09-11 00:02:00
626
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅