I have designed a label in QT Designer and need to set the text from the cpp implementation. This works. But, the text formmatting (size and bold) is being removed.
How can I set the text while preserving the formatting done in the ui file?
Sample:
ui->label_version->setText(QString::fromStdString("1.0.0"));
I found the real issue. I had set the text formatting within the rich text editor. What I needed to do was to set the formatting for the label withing the QtWidget properties. When this was changed all was preserved when setting a new text.