-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Description
Describe the problem
Currently Tauri uses libappindicator to create tray icons on Linux. But it has far fewer features than the xdg standard, as well as macOS and Windows.
There are multiple bug reports and feature requests regarding tray icon issues on Linux.
In particular it's not possible to handle left clicks and to add tool tips.
Describe the solution you'd like
I would like to use the xdg standard for tray icons, which is supported on all Linux desktop environments and has many more features than libappindicator. Also libappindicator looks pretty dead. The last commit to the src folder is 15 years old.
https://bazaar.launchpad.net/~indicator-applet-developers/libappindicator/trunk/files
It looks to me like https://github.com/iovxw/ksni is a great fit for this task. It should be fairly easy to integrate it into Tauri.
I'm ready to write the necessary code myself. I just want to know if you are interested in merging it and if you would like to keep libappindicator as a choice, or if I can remove it.
Alternatives considered
No response
Additional context
No response
Metadata
Metadata
Assignees
Type
Projects
Status
Activity
FabianLars commentedon Oct 10, 2024
Yes, this is desirable, see tauri-apps/tray-icon#107 and tauri-apps/tray-icon#104 for example.
Probably yeah, the only thing i'm not sure how to best approach is the inter-op with
muda
.dfaust commentedon Oct 10, 2024
Ok, great. Sounds like you would like to remove libappindicator as well. I'll start working on it then.
dfaust commentedon Oct 20, 2024
@FabianLars: Integrating it with muda really is a pain. After a few iterations of shoehorning it in, I came up with the following changes. Please have a look at them. If you don't have any major concerns, I will update the docs and create the merge requests.
tauri-apps/tray-icon@dev...dfaust:tray-icon:ksni
tauri-apps/muda@dev...dfaust:muda:ksni
FabianLars commentedon Oct 20, 2024
Let me pull in @amrbashir the maintainer of the crates in question. I'll still try to take a look myself but i'm still out sick so idk when i can get to it.
amrbashir commentedon Oct 29, 2024
@dfaust thank you for the hard work, this looks very promising, please feel free to open the PRs and we will discuss the finer details
Weathercold commentedon Jul 16, 2025
I have no problem with migrating to ksni, but have you considered libayatana-appindicator, which is supposed to be a GTK-free continuation of libappindicator? https://github.com/AyatanaIndicators/libayatana-appindicator-glib
FabianLars commentedon Jul 16, 2025
we're using the "old" version that still relied on gtk in conjunction with libappindicator because both libayatana-appindicator and libappindicator aren't available on all distros (together they are covering all though).
the new
-glib
version would be interesting since it should work together with gtk4 but it's not available in any distro yet (except debian unstable) as far as i can tell and it also has the same feature set so stuff like onclick events are still missing. Since the ksni PR(s) are already in a pretty good state i don't think it's worth to look into this new version.