Skip to content

Commit

Permalink
Ensure Mixxx uses "windowsvista" Qt style on Windows, as our skinning…
Browse files Browse the repository at this point in the history
… looks inconsistent with Qt's "windows" or "windows11" styles

Add logging of the selected style on all platforms
  • Loading branch information
JoergAtGithub committed Jan 26, 2025
1 parent a2b268c commit 105f6b6
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions src/mixxxapplication.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,19 @@ MixxxApplication::MixxxApplication(int& argc, char** argv)
m_isDeveloper(CmdlineArgs::Instance().getDeveloper()) {
registerMetaTypes();

#if defined(Q_OS_WIN)
// The Mixxx style is based on Qt's WindowsVista style
QApplication::setStyle("windowsvista");
#endif

qInfo() << "Selected Qt style:" << QApplication::style()->objectName();

Check failure on line 106 in src/mixxxapplication.cpp

View workflow job for this annotation

GitHub Actions / Ubuntu 22.04

invalid use of incomplete type ‘class QStyle’

Check failure on line 106 in src/mixxxapplication.cpp

View workflow job for this annotation

GitHub Actions / clazy

member access into incomplete type 'QStyle'

Check failure on line 106 in src/mixxxapplication.cpp

View workflow job for this annotation

GitHub Actions / macOS 13 x64

member access into incomplete type 'QStyle'

Check failure on line 106 in src/mixxxapplication.cpp

View workflow job for this annotation

GitHub Actions / coverage

invalid use of incomplete type ‘class QStyle’

Check failure on line 106 in src/mixxxapplication.cpp

View workflow job for this annotation

GitHub Actions / macOS 13 arm64

member access into incomplete type 'QStyle'

#if defined(Q_OS_WIN)
VERIFY_OR_DEBUG_ASSERT(QApplication::style()->objectName() == "windowsvista") {
qWarning() << "Failed to set Qt style to windowsvista";
}
#endif

// Increase the size of the global thread pool to at least
// 4 threads, even if less cores are available. These threads
// will be used for loading external libraries and other tasks.
Expand Down

0 comments on commit 105f6b6

Please sign in to comment.