Qt之QString与wchar_t 互相转换
作者:互联网
1、代码
wchar_t *QString2Wchar(QString buf) { return (wchar_t*)reinterpret_cast<const wchar_t *>(buf.utf16()); } QString Wchar2QString(wchar_t *buf) { return QString::fromWCharArray(buf); }
参考:https://blog.csdn.net/qq_45662588/article/details/123799322
标签:return,Qt,blog,csdn,QString,wchar,buf 来源: https://www.cnblogs.com/judes/p/16310171.html