设置qt程序主体样式

QApplication::setStyle(QStyleFactory::create(tr("cleanlooks")));

TheQStyleclass is an abstract base class that encapsulates the look and feel of a GUI. QStyleFactory creates aQStyleobject using thecreate() function and a key identifying the style. The styles are either built-in or dynamically loaded from a style plugin (seeQStylePlugin).

The valid keys can be retrieved using thekeys() function. Typically they include "windows", "motif", "cde", "plastique" and "cleanlooks". Depending on the platform, "windowsxp", "windowsvista" and "macintosh" may be available. Note that keys are case insensitive.

你可能感兴趣的:(qt)