Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
“Bold” style is not available for “Sans Serif” font on QT5
JieLiu last edited by
We just moved our application from QT4 to QT5. We found the "Bold" style is not avialble for "Sans Serif" font on QT5. I can tell from the QFontDialog which looks below:
I also use the following code to dump all available styles under "Sans Serif"
QFontDatabase db; auto list = db.styles("Sans Serif"); for(auto& l : list) std::cout << l << " ";
I got the same list which is Normal, Italic and Oblique. However I can see the Bold and Bold Italic options on QT4. My question is how the mapping from font to font style is implemented. Am I able to configure something to make the "Bold" avalialble for "Sans Serif" font in QT5.