Qt – Is the Qt 5 dark Fusion theme available for Windows

qtqt5stylesheetthemes

After some research I found out, that Qt 5 now offers a so called Fusion theme which is desribed in one of their blog posts. I really like the theme with the black color configuration you can see in the last picture and I would like to use this in my application but it seems like this color scheme is forced by Unity/Gnome3 (looks like an Ubuntu window) so I am eager to knowing whether there is any available stylesheet or workaround to apply this dark version of the theme to an application.

Best Answer

I'm sure you already found it, but, as TheBootroo said, Fusion theme is controlled by the color palette.

I've found a recreation of the palette here. It isn't complete at all!

qApp->setStyle(QStyleFactory::create("Fusion"));
QPalette p = qApp->palette();
p.setColor(QPalette::Window, QColor(53,53,53));
p.setColor(QPalette::Button, QColor(53,53,53));
p.setColor(QPalette::Highlight, QColor(142,45,197));
p.setColor(QPalette::ButtonText, QColor(255,255,255));
p.setColor(QPalette::WindowText, QColor(255,255,255));
qApp->setPalette(p);

Edit: I've created a gist so we can make it feature-complete.