Details
-
Bug
-
Resolution: Done
-
P2: Important
-
5.4.0 Beta
-
None
-
OS X 10.10
-
-
130c2baa9376dcf525916620294bd9996bdf41f3
Description
In order to have the system tray icon work on OS X the image/icon needs to be set as a template image (see https://developer.apple.com/library/mac/documentation/Cocoa/Reference/ApplicationKit/Classes/NSImage_Class/index.html#//apple_ref/occ/instm/NSImage/setTemplate:).
As of OS X 10.10 Yosemite the user may choose a dark dock and menu bar variant instead of the usual light gray. System tray icons for OS X have usually been black. Those are nearly unspottable on the dark menubar.
When setting the template property to true on NSImages, the image will be considered something like an alpha mask and colors (like black or white) will be applied depending on the current environment. Thus, system tray icons will render black on the default menu bar and white on the dark menu bar when the template property is set to true.
Attachments
Issue Links
- relates to
-
QTBUG-77189 QSystemTrayIcon on macOS does not invert color on selection
- Closed
For Gerrit Dashboard: QTBUG-42109 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
115120,10 | Add ability for QIcons to be marked as template images. | dev | qt/qtbase | Status: MERGED | +2 | 0 |