Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
Print a degrees symbol
kgregory last edited by kgregory
I'm using QStream and QTextStream to format text that is displayed on a QML Text object in my app. I want to print a degrees symbol (°). How can I do this?
I tried putting the character in my string literal, which worked except that it also printed an "A" with an accent.
vivekyuvan last edited by
@kgregory use this symbol before your Text "\xB0"
EX : setText("\xB0 C");
EX : this->ui->Temp_label_unit->setText("\xB0 C");
output will be like this °C