Unsolved FontAwesome, Qt in Windows
-
I use FontAwesome (https://fortawesome.github.io/Font-Awesome/)
//--- painter->setFont(QFont("FontAwesome", dt)); QString str = QChar(0xf24e); painter->drawText(QPointF(x, y), str); //---
In windows, with locale English, Instead of the desired character is displayed "?"
In Windows, with locale Russian or Ukrainian, and in Linux all is well.How to fix it?
-
Hi,
How are you loading FontAwesome ?
-
I added font in qrc.
-
Hi Trikrista,
at least when using Qt on an embedded system, the system needs to know about the font (http://doc.qt.io/qt-5/qt-embedded-fonts.html). I guess this is also the case with Qt on Desktop devices. Can you maybe install the font on the system where you're running the qt program?
Markus
PS: On http://doc.qt.io/qt-4.8/qfontdatabase.html there's an example on how to show a list of the fonts being recognized by the system.