摘要:
1、 模型视图实例一, QFileSystemModel QTreeView ,model/view示例。#include #include #include #include #include #include int main(int argc, char *argv[]){ QApplication a(argc, argv); QFileSystemModel model; model.setRootPath("/"); QTreeView tree; tree.setModel(&model); tree.setRootIndex(model.in... 阅读全文
摘要:
#include "widget.h"#include #include #include #include int main(int argc, char *argv[]){ QApplication a(argc, argv); QTextCodec::setCodecForTr(QTextCodec::codecForLocale()); /*QStringList drivers = QSqlDatabase::drivers(); //获取支持的SQL驱动 for( int i=0; i!=drivers.count(); i++ ) qDebu... 阅读全文