Important: Please read the Qt Code of Conduct -

How to decode QString containing Unicode escape sequences?

  • I'd like to read the text() of QLineEdit that could contain characters encoded as Unicode escape sequences.
    Example: "Faction name: \u2662 \u8f1d \u2662". That I want to decode and display as proper characters in a QLabel.

    Is there an easy way to do it with standard Qt functions?
    Well also other alternatives would be interesting too: C++ and Python.

Log in to reply