Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a class or library somewhere that makes it easy to use the new AppIndicator framework from within a Qt application?

It seems strange that I should have to include GTK headers / libraries etc. just to create an indicator in Qt.

Is there a better way?

share|improve this question
up vote 4 down vote accepted

appmenu-qt is about exposing the menubar of Qt/KDE applications so that it appears in Unity panel. It is not about appindicators.

There is no explicit API to use appindicators from a Qt applications now. There should be one for Ubuntu 12.04. Until this is available, the two possible solutions are:

  • Use the QSystemTrayIcon and ensure your users install the sni-qt package (sni-qt transparently turns a QSystemTrayIcon into a StatusNotifierItem|AppIndicator)
  • Use the KStatusNotifierItem class from kdelibs
share|improve this answer

Seems like there is finally a great answer to this:

On Launchpad, there is a package that provides a Qt class for setting a QMenuBar as an AppMenu:

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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