Apply selected style to window elements on macOS
Qt doesn't apply the proper style to elements such as the title bar or text shadows, so this must be done in native code. Signed-off-by: Kenneth Chew <79120643+kthchew@users.noreply.github.com>
This commit is contained in:
@@ -81,6 +81,15 @@ class ThemeManager {
|
||||
void initializeIcons();
|
||||
void initializeWidgets();
|
||||
|
||||
// On non-Mac systems, this is a no-op.
|
||||
void setTitlebarColorOnMac(WId windowId, QColor color);
|
||||
// This also will set the titlebar color of newly opened windows after this method is called.
|
||||
// On non-Mac systems, this is a no-op.
|
||||
void setTitlebarColorOfAllWindowsOnMac(QColor color);
|
||||
#ifdef Q_OS_MACOS
|
||||
NSObject* m_windowTitlebarObserver = nullptr;
|
||||
#endif
|
||||
|
||||
const QStringList builtinIcons{ "pe_colored", "pe_light", "pe_dark", "pe_blue", "breeze_light", "breeze_dark",
|
||||
"OSX", "iOS", "flat", "flat_white", "multimc" };
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user