QT——支持显示中文,不出现乱码

版权声明:本文为博主原创文章,如有需要,可以转载,但请注明出处。 https://blog.csdn.net/xunye_dream/article/details/83002523

在main文件中引入头文件#include <QTextCodec>

并在main函数中加入

QTextCodec::setCodecForTr(QTextCodec::codecForLocale());   //显示中文设置

猜你喜欢

转载自blog.csdn.net/xunye_dream/article/details/83002523
今日推荐