摘要: Q_DECLARE_METATYPE与qRegisterMetaType学习 http://hi.baidu.com/cyclone/blog/item/01108bd40599b00fa18bb793.html 2010-09-07 18:20 基本理解 Q_DECLARE_METATYPE 如果要使自定义类型或其他非QMetaType内置类型在QVaiant中使用,必须使用该宏。 该类型必须有... 阅读全文
posted @ 2011-03-02 17:56 katago 阅读(5922) 评论(0) 推荐(0)
摘要: 浅谈ARM裸板调试15309101313 2009-8-3 13:56:11 收藏 | 打印 | 投票(1) | 评论(0) | 阅读(15938) ◇字体:[大 中 小] 作者:ARM-WinCE 我所说的ARM裸板调试是指ARM的PCB板制作完后,贴片回来的板子,不但没有任何程序,上电都是第一次。之所以写一篇blog,是因为最近调试了一块ARM板,基于S3C6410的,但是我们把原来的M-DD... 阅读全文
posted @ 2011-03-02 15:09 katago 阅读(482) 评论(0) 推荐(0)
摘要: 参考http://en.wikipedia.org/wiki/UTF-16 UTF-16 is used by the Qualcomm BREW operating systems; the .NET environments; Mac OS X's Cocoa and Core Foundation frameworks; and the Qt cross-platform graphica... 阅读全文
posted @ 2011-03-02 13:59 katago 阅读(712) 评论(0) 推荐(0)
摘要: 如何在Qt中使用自定义数据类型 Q_DECLARE_METATYPE, Qt自定义类型 这里我们使用下面这个struct来做说明(这里不管是struct还是class都一样): struct Player { int number; QString firstName; QString lastName; }; 复制代码 QVariant 为了能在QVariant中使用自定义数据类型做,需要使... 阅读全文
posted @ 2011-03-01 18:57 katago 阅读(19508) 评论(2) 推荐(3)
摘要: 开始 阅读全文
posted @ 2011-03-01 16:31 katago 阅读(224) 评论(0) 推荐(0)
摘要: C++ template Day Day Up 第二天 模板参数推论(deduction) 收藏 Today’s subject is Compile Argument Deduction. 我们平时用template的时候往往需要指定template argument type,实际上很多种情况可以不指定具体的类型,而依赖于编译器的deduction(个人推荐把这个单词翻译成推论,能表达出实际的... 阅读全文
posted @ 2011-03-01 16:24 katago 阅读(567) 评论(0) 推荐(0)
摘要: 析构时候清除pointer template <typename T> struct QScopedPointerDeleter { static inline void cleanup(T *pointer) { // Enforce a complete type. // If you get a compile error here, read the secion on forw... 阅读全文
posted @ 2011-03-01 16:01 katago 阅读(1220) 评论(0) 推荐(0)
摘要: [Qt] QScopedPointer介绍 QScopedPointer 就分配空间和释放空间而言,Qt的处理有点乏味,要不然是通过隐式共享的containers,要不然就是通过QObject的父子关系模式。但总有些时候我们需要在堆上分配一些空间,问题来了,我们该在哪里delete它,如何能够确保不产生内存泄露呢? QScopedPointer就为了解决这个问题而生的,哈哈 QScopedPoin... 阅读全文
posted @ 2011-03-01 15:20 katago 阅读(14602) 评论(0) 推荐(0)
摘要: #ifndef SETTINGS_H #define SETTINGS_H #include <QString> #include <QVariant> class QSettings; class Settings { public: Settings(const QString & fileName); ~Settings(); void setValue ( const QString... 阅读全文
posted @ 2011-03-01 14:49 katago 阅读(3193) 评论(0) 推荐(0)
摘要: http://hi.baidu.com/cyclone/blog/item/1bcb5edfed60d20348540320.html 阅读全文
posted @ 2011-02-28 18:24 katago 阅读(528) 评论(0) 推荐(0)