PDA

View Full Version : name of current QStyle



darksaga
31st August 2007, 20:57
hi there,

i need to get my hands on the name of the current QStyle name.

follwoing code:


QStyle *currentStyle = QApplication::style();
qDebug() << "currentStyle " << currentStyle;
qDebug() << "currentStyle " << currentStyle->metaObject()->className();

shows

currentStyle QWindowsXPStyle(ptrAddress, name = "windowsxp")
currentStyle QWindowsXPStyle

on the console

"windowsxp" is the property I'd like to get

anyone knows how to do this?

marcel
31st August 2007, 21:02
What about currentStyle->objectName()?

EDIT: yes, it works. just tested it...

Regards