Skip to content

Instantly share code, notes, and snippets.

@International
Forked from candidtim/myappindicator_v1.py
Created December 24, 2015 07:41
Show Gist options
  • Save International/eab7869447144e98571b to your computer and use it in GitHub Desktop.
Save International/eab7869447144e98571b to your computer and use it in GitHub Desktop.
Minimal set-up for an Ubuntu AppIndicator in Python
from gi.repository import Gtk as gtk
from gi.repository import AppIndicator3 as appindicator
APPINDICATOR_ID = 'myappindicator'
def main():
indicator = appindicator.Indicator.new(APPINDICATOR_ID, 'whatever', appindicator.IndicatorCategory.SYSTEM_SERVICES)
indicator.set_status(appindicator.IndicatorStatus.ACTIVE)
indicator.set_menu(gtk.Menu())
gtk.main()
if __name__ == "__main__":
main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment