易妖游戏网
您的当前位置:首页QT5 Utf-8打印转换

QT5 Utf-8打印转换

来源:易妖游戏网

   

QString strText = ui->printContent_TextEdit->toPlainText()+"\n";
QTextCodec* code = QTextCodec::codecForName("GB-2312");
QByteArray ba = code->fromUnicode(strText);
 BOOL bRet =HSSendStrPrn((LPCTSTR)ba.data(),ba.size());

因篇幅问题不能全部显示,请点此查看更多更全内容