I'm trying to use KMail from KDE4, but with XFCE4 panel instead of Plasma panel. So far I get most of the icons from other applications, but no icon from KMail.

It seems it's because KMail uses KSystemNotifierItem, which requires special support from the panel system tray applet, and it looks like XFCE4 panel doesn't support it.

How do I make this work? Is there any way to enable SNI support for XFCE4 panel (if it's not there already)?

up vote 0 down vote accepted

OK, so this problem happens only when using KMail+XFCE4 panel in KDE session. KStatusNotifier appears to be smart, and somehow checks whether it's in KDE, and bases its mechanism on this. So to have KMail work correctly with XFCE4 panel in KDE session, we have to trick KMail into thinking that it's not in KDE:


The above command clears the environment and only saves HOME and DISPLAY variables before running kmail. These variables are basically all what are needed for KMail to work properly without KDE session support.

Actually this is true not only for KMail, but for virtually any KDE application with a system tray icon: KTorrent, Amarok, etc.. The above trick should work for all of them (maybe adding more variables if needed).

Ruslan's answer works. But this leaves kmail running without a window manager. However, in kmail 5.7.0, under settings/configure kmail.../general there is a "System tray" panel with a checkbox for "Enable system tray icon". Clearing that checkbox and clicking OK allows kmail to run under xfce with no problems. Hurray!

Your Answer


By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.