Skip to content

Add mask-based tray icon for macOS#2091

Merged
m3nu merged 2 commits intoborgbase:masterfrom
alecdwm-forks:mask-tray-icon-macos
Oct 18, 2024
Merged

Add mask-based tray icon for macOS#2091
m3nu merged 2 commits intoborgbase:masterfrom
alecdwm-forks:mask-tray-icon-macos

Conversation

@alecdwm
Copy link
Contributor

@alecdwm alecdwm commented Oct 9, 2024

Description

Reviving #1694, but with a twist!
Instead of polling the screen for the light/dark icons state, we can use the native support for template tray icons by calling QIcon.setIsMask(True).
Note: template icons are monochrome, so I added some inner circles to the indicators of the active state.

Related Issues

Screenshots

Current mainline
old-dark old-dark-active old-light old-light-active

This PR
dark dark-active light light-active

Types of changes

  • Bug fix (non-breaking change which fixes an issue)

Checklist:

  • I have read the CONTRIBUTING guide.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

I provide my contribution under the terms of the license of this repository and I affirm the Developer Certificate of Origin.

@m3nu
Copy link
Contributor

m3nu commented Oct 18, 2024

That's great! Works as expected locally.

@m3nu m3nu self-assigned this Oct 18, 2024
@m3nu m3nu merged commit 4aea368 into borgbase:master Oct 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants