QT embedded and fonts
-
Hi there,
I am currently developing a QT5 embedded app on a ARM linux device (Toradex VF61).
All working fine for first steps. A simple widget app will be shown.
But the labels do have some small system font. I do not know which one. QT5 does not have makeqpf support or QConfig support, so I think freetype may be enabled and qpf also? No feature files are available.
I have moved my ttf font to the resource of my app and load and set it to a label. On linux 64bit the app will set the resource font to my label. On arm embedded linux not (app compiled for arm).
Did someone get a successfully way to set a font in QT5 embedded?I do not have the standard font directories and no fontdir on my arm device, I use resources.
Best regards,
SirNoname -
Hi,
Are you using "QFontDatabase":http://doc.qt.io/qt-5/qfontdatabase.html to handle your custom font ?
-
use setPixelSize() instead of setPointSize().
I am guessing you and I misconfigured something when we built Qt for the ARM and the fonts are not rendering as expected. I did this and all is exactly the way I want.
I also had to hack QCustomPlot a bit for the same reason. If you will use plots, I recommend it and I can share the hac.
-
What type of font is it ?