Qt
泉自无声
这个作者很懒,什么都没留下…
展开
-
QT 输出重定向到文件
void qtLogToFile(QtMsgType type, const QMessageLogContext &context, const QString &msg) { const std::string logTypes[] = { "Debug", "Warning", "Critical", "Fatal", "Info" }; st...原创 2019-12-17 10:58:45 · 1427 阅读 · 0 评论 -
Qt中文路径
在mian函数中设置编码: 1. 指定Qt库plugins/codecs的路径,如果QT库设置了环境变量,可不指定。 app.addLibraryPath(appDir + "/plugins"); app.addLibraryPath(appDir + "/plugins/codecs"); 2. 设置编码为 utf-8 QTextCodec *codec = Q...原创 2018-08-06 15:09:00 · 1400 阅读 · 0 评论