alltray has an excellent option that gives us great customizability:
--menu; -m: "menu text:command": add entry to popdown menu
just to run test it I am using tho ex.: alltray xev
it is installable on ubuntu 16.04.
using kwin it will fail with
ERROR get class hints
using with metacity (my preferred for speed) or compiz gives
Alltray: no system tray/notification area found.
what can be done to let it work? preferably on metacity.
as an alternative answer, any equivalent application or script that has an equivalent option to --menu will do it.
this wont work, outdated.