Home  >  Q&A  >  body text

c++ - qt 如何用 QTextEdit显示cout输出的内容

阿神阿神2765 days ago710

reply all(1)I'll reply

  • 黄舟

    黄舟2017-04-17 14:48:56

    textEdit can receive QString type, so you need to convert it. The conversion is not troublesome.

    QString qsStr = QString(char *);
    textEdit->append(qsStr);

    reply
    0
  • Cancelreply