Last active
August 29, 2015 14:02
-
-
Save lidio601/25ce553b44cca6abc658 to your computer and use it in GitHub Desktop.
pynotify Notify OSD
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pynotify | |
if not pynotify.init("GMail Notifier"): | |
sys.exit(-1) | |
n = pynotify.Notification("titolo", "messaggio blablablalbalblabl\nciao", "notification-network-wirelessq") | |
#/usr/share/notify-osd/icons/hicolor/scalable/status | |
#notification-audio-next.svg | |
#notification-audio-play.svg | |
#notification-audio-previous.svg | |
#notification-audio-volume-high.svg | |
#notification-audio-volume-low.svg | |
#notification-audio-volume-medium.svg | |
#notification-audio-volume-muted.svg | |
#notification-audio-volume-off.svg | |
#notification-battery-low.svg | |
#notification-device-eject.svg | |
#notification-device.svg | |
#notification-display-brightness.svg | |
#notification-keyboard-brightness.svg | |
#notification-message-email.svg | |
#notification-message-IM.svg | |
#notification-network-ethernet-connected.svg | |
#notification-network-ethernet-diconnected.svg | |
#notification-network-wireless.svg | |
#notification-power.svg | |
n.set_urgency(pynotify.URGENCY_NORMAL) | |
#n.set_timeout(pynotify.EXPIRES_NEVER) | |
n.set_timeout(2500) | |
#def callback_function(notification=None, action=None, data=None): | |
# print "It worked!" | |
#n.add_action("clicked","Button text", callback_function, None) | |
n.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment