Parsa Mousavi
Parsa Mousavi

Reputation: 1182

How to get a list of all available themes in Qt C++?

Is there a way to get a list of all installed themes(e.g "motif" ,"gtk+" etc) in Qt via C++ API?

Upvotes: 1

Views: 1406

Answers (1)

eyllanesc
eyllanesc

Reputation: 243945

Assuming you want to get the list of styles that Qt can use then you must use QStyleFactory::keys():

qDebug() << QStyleFactory::keys();

Output:

("bb10dark", "bb10bright", "cleanlooks", "gtk2", "cde", "motif", "plastique", "Windows", "Fusion")

Upvotes: 3

Related Questions