lwindolf / liferea

Liferea (Linux Feed Reader), a news reader for GTK/GNOME
https://lzone.de/liferea
GNU General Public License v2.0
817 stars 130 forks source link

Add Ayatana AppIndicator backend to trayicon plugin #1309

Closed nE0sIghT closed 11 months ago

nE0sIghT commented 11 months ago

Since GNOME 3.26 Shell do not show tray icons and Gtk.StatusIcon is deprecated for some time.

There were several GNOME extensions that implements system tray and actual extension is AppIndicator and KStatusNotifierItem Support. This extension supports both Freedesktop's System Tray Protocol and StatusNotifierItem specification.

The problem with System Tray Protocol is that it doesn't works with Wayland obviously. And for some reasons Liferea's Gtk.StatusIcon looks weird for me [1].

With this change StatusNotifierItem icon [2] is added to trayicon plugin through Ayatana Application Indicator and made preferred tray icon implementation if libayatana-appindicator is available.

[1] Screenshot from 2023-10-11 21-57-46

[2] Screenshot from 2023-10-11 23-09-17

lwindolf commented 11 months ago

Will try this out soon. Sounds like a good idea, although it is hard to get an idea how common Ayatana indicators are among the user base.

nE0sIghT commented 11 months ago

I added minor change to support legacy Canonical Appindicator too (Ayatana appindicator is the fork).
As per Repology [1][2] both the legacy appindicator and the ayatana-appindicator are widelly adopted by Linux distros.

In my Gentoo box it is used by NetworkManager applet and Remmina. It looks like it's used by Transmission too.

[1] https://repology.org/project/libappindicator/versions [2] https://repology.org/project/libayatana-appindicator/versions