I want to add all fonts from my pc to QComboBox, how can I do it?
I expect a combobox list which will include all fonts from my PC. As I think, it can be possible with QFontDatabase.
As said in comments to your question, QFontComboBox
should be helpful.
But for some reason if you are not interested in that, you can do it in traditional way.
Get the font families as a string list using QFontDatabase::families(), and then fill the combobox:
comboBox->addItems(QFontDatabase::families());