Reply to topic

Plasmoid doesn't appear in System Tray

User avatar MirceaKitsune
Registered Member
Posts
248
Karma
0
OS
Greetings. I'm having a problem with the development of a plasmoid; I'm trying to make it appear as an option in the System Tray (General -> Extra Items) but for some reason it refuses to show up there. I looked at the example of another Plasma widget that does get listed, yet for an inexplicable cause mine does not.

https://community.kde.org/Plasma/Develo ... oid_Status

I understand that I primarily need to add an extra line to my metadata.desktop file, which I have with no result:

Code: Select all
X-Plasma-NotificationArea=true


Any thought on how to fix this please? Thank you.
Rog131
Registered Member
Posts
738
Karma
10
It seems that the 'Extra Items' are read from the plasmoids kpluginindex.json. An example:


Making a dummy plasmoid, only the metadata.desktop. $HOME/.local/share/plasma/plasmoids/Dummy/metadata.desktop:

Code: Select all
[Desktop Entry]
Name=Dummy
Comment=Show Dummy
Encoding=UTF-8
Icon=drink-beer
ServiceTypes=Plasma/Applet
Type=Service
X-KDE-PluginInfo-Name=Dummy
X-Plasma-NotificationArea=true
X-Plasma-API=declarativeappletscript
X-Plasma-MainScript=ui/main.qml


Executing command kpackagetool5 to generate the index file:
Code: Select all
$ kpackagetool5 --generate-index -t Plasma/Applet
Generating /home/rog131/.local/share/plasma/plasmoids//kpluginindex.json
Generated  "/home/rog131/.local/share/plasma/plasmoids//kpluginindex.json"  ( 22  plugins)


Restarting the plasmashell.....

Now the System Tray Settings has an Extra Item:

Image
User avatar MirceaKitsune
Registered Member
Posts
248
Karma
0
OS
Wow... so it was a Plasma caching issue all along. Running "kpackagetool5 --generate-index -t Plasma/Applet" and restarting plasmashell immediately caused my plasmoid's icon to appear successfully!

The developers should really think of a way to automate this, so that Plasma can automatically detect when system tray widgets are installed or uninstalled. I didn't even consider this might not be the case and you have to update it manually.

[EDIT] I created a bug report about this: https://bugs.kde.org/show_bug.cgi?id=386880

 
Reply to topic

Bookmarks



Who is online

Registered users: Baidu [Spider], bartoloni, Bing [Bot], boudewijn, Google [Bot], interele, Majestic-12 [Bot], Mamarok, progdan, semper, Sogou [Bot]