From c21596328efae51a31d49c1d6a9f9cc0b520be59 Mon Sep 17 00:00:00 2001 From: Patrick Ulbrich Date: Sat, 16 Apr 2011 13:29:40 +0000 Subject: [PATCH] replaced all occurrences of 'popper' with 'mailnag' renamed and removed some more files --- popper.png => mailnag.png | Bin popper.py => mailnag.py | 46 +- popper.sh => mailnag.sh | 6 +- popper.wav => mailnag.wav | Bin mailnag_config.desktop.desktop | 14 + popper_config.glade => mailnag_config.glade | 32 +- popper_config.py => mailnag_config.py | 102 ++- mailnag_config.sh | 21 + popper_icon.png => mailnag_icon.png | Bin popper_keyring.glade => mailnag_keyring.glade | 4 +- popper_message.glade => mailnag_message.glade | 2 +- popper_changelog.txt | 333 ---------- popper_config.desktop | 17 - popper_config.sh | 21 - popper_help_de.txt | 621 ------------------ popper_help_en.txt | 567 ---------------- popper_list.glade | 80 --- popper_list.py | 122 ---- 18 files changed, 123 insertions(+), 1865 deletions(-) rename popper.png => mailnag.png (100%) rename popper.py => mailnag.py (95%) rename popper.sh => mailnag.sh (64%) rename popper.wav => mailnag.wav (100%) create mode 100644 mailnag_config.desktop.desktop rename popper_config.glade => mailnag_config.glade (99%) rename popper_config.py => mailnag_config.py (92%) create mode 100755 mailnag_config.sh rename popper_icon.png => mailnag_icon.png (100%) rename popper_keyring.glade => mailnag_keyring.glade (97%) rename popper_message.glade => mailnag_message.glade (97%) delete mode 100644 popper_changelog.txt delete mode 100644 popper_config.desktop delete mode 100755 popper_config.sh delete mode 100644 popper_help_de.txt delete mode 100644 popper_help_en.txt delete mode 100644 popper_list.glade delete mode 100644 popper_list.py diff --git a/popper.png b/mailnag.png similarity index 100% rename from popper.png rename to mailnag.png diff --git a/popper.py b/mailnag.py similarity index 95% rename from popper.py rename to mailnag.py index 49ffd0d..8fb92c8 100644 --- a/popper.py +++ b/mailnag.py @@ -1,8 +1,9 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- # -# popper.py +# mailnag.py # +# Copyright 2011 Patrick Ulbrich # Copyright 2011 Ralf Hersel # # This program is free software; you can redistribute it and/or modify @@ -20,15 +21,6 @@ # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, # MA 02110-1301, USA. # -#======================================================================= -# POPPER : An indicator and notifier for new emails -# -# Author : Ralf Hersel, ralf.hersel@gmx.net -# Version: 0.28 -# Date : Apr 12, 2011 -# Licence: GPL -# -# Libraries ============================================================ import poplib import imaplib @@ -46,13 +38,13 @@ from email.header import decode_header import sys #import locale import gettext -from popper_config import Keyring +from mailnag_config import Keyring #import cairo import signal -gettext.bindtextdomain('popper', 'locale') -gettext.textdomain('popper') +gettext.bindtextdomain('mailnag', 'locale') +gettext.textdomain('mailnag') _ = gettext.gettext # Accounts and Account ================================================= @@ -438,15 +430,15 @@ def read_config(cfg_file): # read config file or create it return cfg -def write_pid(): # write Popper's process id to file - pid_file = user_path + 'popper.pid' +def write_pid(): # write Mailnags's process id to file + pid_file = user_path + 'mailnag.pid' f = open(pid_file, 'w') f.write(str(os.getpid())) # get PID and write to file f.close() -def delete_pid(): # delete file popper.pid - pid_file = user_path + 'popper.pid' +def delete_pid(): # delete file mailnag.pid + pid_file = user_path + 'mailnag.pid' if os.path.exists(pid_file): os.popen("rm " + pid_file) # delete it @@ -493,7 +485,7 @@ def commandExecutor(command, context_menu_command=None): mailchecker.clear() # if indicator.desktop_display != None: # indicator.desktop_display.destroy() - elif command == 'exit': # exit popper immediatelly + elif command == 'exit': # exit mailnag immediatelly delete_pid() exit(0) elif command == 'check': # check immediatelly for new emails @@ -522,7 +514,7 @@ class MailChecker: # self.server.set_desktop_file(desktop_file) # self.server.connect("server-display", self.headline_clicked) # if clicked on headline # self.server.show() - pynotify.init("Pooper") # initialize Notification + pynotify.init("Mailnag") # initialize Notification self.notification = pynotify.Notification(" ", None, None) self.notification.set_category("email") @@ -752,7 +744,7 @@ class MailChecker: for mail in self.mail_list: self.reminder.set_to_seen(mail.id) - self.reminder.save(self.mail_list) # save to popper.dat + self.reminder.save(self.mail_list) # save to mailnag.dat else: # keep 'list' filled self.mail_list = [] # clear mail list @@ -995,9 +987,9 @@ class MailChecker: # Reminder ============================================================= class Reminder(dict): - def load(self): # load last known messages from popper.dat + def load(self): # load last known messages from mailnag.dat remember = cfg.get('indicate', 'remember') - dat_file = user_path + 'popper.dat' + dat_file = user_path + 'mailnag.dat' we_have_a_file = os.path.exists(dat_file) # check if file exists if remember == '1' and we_have_a_file: f = open(dat_file, 'r') # open file again @@ -1007,12 +999,12 @@ class Reminder(dict): try: self[content[0]] = content[1] # add to dict [id : flag] except IndexError: - self[content[0]] = '0' # no flags in popper.dat + self[content[0]] = '0' # no flags in mailnag.dat f.close() # close file def save(self, mail_list): # save mail ids to file - dat_file = user_path + 'popper.dat' + dat_file = user_path + 'mailnag.dat' f = open(dat_file, 'w') # open the file for overwrite for m in mail_list: try: @@ -1220,14 +1212,14 @@ def main(): signal.signal(signal.SIGTERM, cleanup) try: - user_path = os.path.expanduser("~/.popper/") # set path to: "/home/user/.popper/" + user_path = os.path.expanduser("~/.mailnag/") # set path to: "/home/user/.mailnag/" autostarted = False # default setting for command line argument cmdline = sys.argv # get command line arguments if len(cmdline) > 1: # do we have something in command line? if cmdline[1] == 'autostarted': autostarted = True - write_pid() # write Popper's process id to file - cfg = read_config(user_path + 'popper.cfg') # get configuration from file + write_pid() # write Mailnag's process id to file + cfg = read_config(user_path + 'mailnag.cfg') # get configuration from file accounts = Accounts() # create Accounts object if accounts.keyring_was_locked: firstcheck = False # required for correct sortorder in indi menu diff --git a/popper.sh b/mailnag.sh similarity index 64% rename from popper.sh rename to mailnag.sh index 6390feb..f696f5f 100755 --- a/popper.sh +++ b/mailnag.sh @@ -1,11 +1,11 @@ #!/bin/bash main() { -if [ -f ~/.popper/popper.log ]; then - rm ~/.popper/popper.log +if [ -f ~/.mailnag/mailnag.log ]; then + rm ~/.mailnag/mailnag.log fi cd `dirname $0` -python popper.py autostarted >> ~/.popper/popper.log 2>&1 & +python mailnag.py autostarted >> ~/.mailnag/mailnag.log 2>&1 & } connection() diff --git a/popper.wav b/mailnag.wav similarity index 100% rename from popper.wav rename to mailnag.wav diff --git a/mailnag_config.desktop.desktop b/mailnag_config.desktop.desktop new file mode 100644 index 0000000..771e403 --- /dev/null +++ b/mailnag_config.desktop.desktop @@ -0,0 +1,14 @@ + +[Desktop Entry] +Name=Mailnag Configuration +Name[de]=Mailnag Configuration +Comment=A notifier for new emails +Comment[de]=Ein Benachrichtiger für neue Emails +Exec=/usr/share/mailnag/mailnag_config.sh +Icon=/usr/share/mailnag/mailnag_icon.png +Terminal=false +Type=Application +Categories=Network; +StartupNotify=false + +Name[de_DE]=mailnag_config.desktop diff --git a/popper_config.glade b/mailnag_config.glade similarity index 99% rename from popper_config.glade rename to mailnag_config.glade index f3e3082..6b0ba29 100644 --- a/popper_config.glade +++ b/mailnag_config.glade @@ -13,10 +13,10 @@ - Popper Configurator + Mailnag Configuration False center - popper.png + mailnag.png @@ -32,14 +32,14 @@ True 10 - Popper - Email Notifier & Indicator + Mailnag - Email Notifier & Indicator Ralf Hersel, Patrick Benz - 2011 - GPL center @@ -50,7 +50,7 @@ Ralf Hersel, Patrick Benz - 2011 - GPL - Start Popper automatically after login + Start Mailnag automatically after login True True False @@ -168,7 +168,7 @@ Otherwise keep it empty. True True For IMAP accounts you can enter folder names -that should be read. If empty, Popper reads the +that should be read. If empty, Mailnag reads the INBOX only. Multiple folders must be separated by comma. @@ -421,7 +421,7 @@ form Gnome Keyring. False True Check for new emails once immediately after start-up -and then never again. Popper terminates after first check. +and then never again. Mailnag terminates after first check. True @@ -445,7 +445,7 @@ and then never again. Popper terminates after first check. True True True - Every x minutes Popper + Every x minutes Mailnag checks for new emails. Min: 1 Max: 1440 = 24h 4 @@ -1001,7 +1001,7 @@ Minimum value is 10. True False True - Stores the email list so that Popper + Stores the email list so that Mailnag knows the status when you reboot your PC. True @@ -1224,7 +1224,7 @@ you receive new emails. True Path and name of the sound file that is played when new emails -arrive. Standard is 'popper.wav' +arrive. Standard is 'mailnag.wav' 61 @@ -1770,7 +1770,7 @@ arrive. Standard is 'popper.wav' True False True - Switch this on if you want Popper + Switch this on if you want Mailnag to start a shell script whenever new emails arrive. True @@ -1788,7 +1788,7 @@ emails arrive. True False True - Switch this on if you want Popper + Switch this on if you want Mailnag to start a shell script when no new emails are available. True @@ -1869,7 +1869,7 @@ on the left happens. True False True - Switch this on if you want Popper + Switch this on if you want Mailnag to start a shell script when you clicked an email in the indicator menu. True @@ -1887,7 +1887,7 @@ an email in the indicator menu. True False True - Switch this on if you want Popper + Switch this on if you want Mailnag to start a shell script when you click on a account summary entry in the indicator menu, e.g.: Gmail @@ -2271,7 +2271,7 @@ last stored values. True Exit program without doing anything else. Nothing will be -saved. Popper will not be started. +saved. Mailnag will not be started. @@ -2307,7 +2307,7 @@ exit the application. Click button 'Test Email Connection' to start the test. -Do not start Popper before this test succeeds. +Do not start Mailnag before this test succeeds. diff --git a/popper_config.py b/mailnag_config.py similarity index 92% rename from popper_config.py rename to mailnag_config.py index f38e3f6..7418c6a 100644 --- a/popper_config.py +++ b/mailnag_config.py @@ -1,8 +1,9 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- # -# popper_config.py +# mailnag_config.py # +# Copyright 2011 Patrick Ulbrich # Copyright 2011 Ralf Hersel # # This program is free software; you can redistribute it and/or modify @@ -20,15 +21,6 @@ # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, # MA 02110-1301, USA. # -#======================================================================= -# POPPER : An indicator and notifier for new emails -# popper_settings.py is the GUI for configuration settings -# Author : Ralf Hersel, ralf.hersel@gmx.net -# Version: 0.28 -# Date : Apr 08, 2011 -# Licence: GPL -# -# Libraries ============================================================ import gtk import os @@ -47,8 +39,8 @@ import cairo class Settings: def __init__(self): builder = gtk.Builder() # build GUI from Glade file - builder.set_translation_domain('popper_config') - builder.add_from_file("popper_config.glade") + builder.set_translation_domain('mailnag_config') + builder.add_from_file("mailnag_config.glade") builder.connect_signals({ \ "gtk_main_quit" : self.exit, \ "on_button_restore_clicked" : self.restore, \ @@ -198,12 +190,12 @@ class Settings: self.help = builder.get_object("textbuffer_help") # load help text lang = locale.getdefaultlocale()[0].lower() # get language from operating system - if 'de' in lang: - f = open('popper_help_de.txt', 'r') # get german help - else: - f = open('popper_help_en.txt', 'r') # get english help for all other languages - self.help.set_text(f.read()) - f.close() +# if 'de' in lang: +# f = open('mailnag_help_de.txt', 'r') # get german help +# else: +# f = open('mailnag_help_en.txt', 'r') # get english help for all other languages +# self.help.set_text(f.read()) +# f.close() def load(self): # set values to widgets from config @@ -289,7 +281,7 @@ class Settings: def cancel(self, widget): # exit program without doing anything else - exit(1) # exit code used in popper_config.sh + exit(1) # exit code used in mailnag_config.sh def exit(self, widget): # save and exit @@ -368,11 +360,11 @@ class Settings: start, end = self.filter_text.get_bounds() cfg.set('filter', 'filter_text', self.filter_text.get_text(start, end)) - cfg_file = user_folder + ".popper/popper.cfg" # folder: /home/user/.popper/popper.cfg + cfg_file = user_folder + ".mailnag/mailnag.cfg" # folder: /home/user/.mailnag/mailnag.cfg with open(cfg_file, 'wb') as configfile: cfg.write(configfile) headline = self.headline.get_text() # always write headline.. - update_desktop_file(headline) # ..to popper.desktop + update_desktop_file(headline) # ..to mailnag.desktop if autostart == 1: create_autostart() # write autostart else: delete_autostart() @@ -561,7 +553,7 @@ class Settings: dialog = gtk.FileChooserDialog("Open..", None, \ gtk.FILE_CHOOSER_ACTION_OPEN, (gtk.STOCK_CANCEL, \ gtk.RESPONSE_CANCEL, gtk.STOCK_OPEN, gtk.RESPONSE_OK)) # create file dialog - dialog.set_current_folder(user_folder + ".popper") # set default folder + dialog.set_current_folder(user_folder + ".mailnag") # set default folder dialog.set_default_response(gtk.RESPONSE_OK) # set default button to OK response = dialog.run() # show file dialog if response == gtk.RESPONSE_OK: # if OK clicked @@ -770,7 +762,7 @@ class Settings: class Keyring: def __init__(self): - glib.set_application_name('Popper') + glib.set_application_name('mailnag') self.was_locked = False # True if Dialog shown. Required for Sortorder problem self.keyring_password = '' self.defaultKeyring = gnomekeyring.get_default_keyring_sync() @@ -801,13 +793,13 @@ class Keyring: item = gnomekeyring.item_get_info_sync(self.defaultKeyring, identity) displayNameDict[item.get_display_name()] = identity - if 'Popper password for %s://%s@%s' % (protocol, user, server) in displayNameDict: + if 'Mailnag password for %s://%s@%s' % (protocol, user, server) in displayNameDict: if gnomekeyring.item_get_info_sync(self.defaultKeyring, \ - displayNameDict['Popper password for %s://%s@%s' % \ + displayNameDict['Mailnag password for %s://%s@%s' % \ (protocol, user, server)]).get_secret() != '': return gnomekeyring.item_get_info_sync(self.defaultKeyring, \ - displayNameDict['Popper password for %s://%s@%s' % \ + displayNameDict['Mailnag password for %s://%s@%s' % \ (protocol, user, server)]).get_secret() else: # DEBUG print "Keyring.get(): No Keyring Password for %s://%s@%s." % (protocol, user, server) @@ -855,21 +847,21 @@ class Keyring: item = gnomekeyring.item_get_info_sync(self.defaultKeyring, identity) displayNameDict[item.get_display_name()] = identity - if 'Popper password for %s://%s@%s' % (protocol, user, server) in displayNameDict: + if 'Mailnag password for %s://%s@%s' % (protocol, user, server) in displayNameDict: if password != gnomekeyring.item_get_info_sync(self.defaultKeyring, \ - displayNameDict['Popper password for %s://%s@%s' % \ + displayNameDict['Mailnag password for %s://%s@%s' % \ (protocol, user, server)]).get_secret(): gnomekeyring.item_create_sync(self.defaultKeyring, \ gnomekeyring.ITEM_GENERIC_SECRET, \ - 'Popper password for %s://%s@%s' % (protocol, user, server), \ - {'application':'Popper', 'protocol':protocol, 'user':user, 'server':server}, \ + 'Mailnag password for %s://%s@%s' % (protocol, user, server), \ + {'application':'Mailnag', 'protocol':protocol, 'user':user, 'server':server}, \ password, True) else: gnomekeyring.item_create_sync(self.defaultKeyring, \ gnomekeyring.ITEM_GENERIC_SECRET, \ - 'Popper password for %s://%s@%s' % (protocol, user, server), \ - {'application':'Popper', 'protocol':protocol, 'user':user, 'server':server}, password, True) + 'Mailnag password for %s://%s@%s' % (protocol, user, server), \ + {'application':'Mailnag', 'protocol':protocol, 'user':user, 'server':server}, password, True) def remove(self, accounts): # delete obsolete entries from Keyring @@ -880,7 +872,7 @@ class Keyring: valid_accounts = [] for acc in accounts: # create list of all valid accounts protocol = 'imap' if acc.imap else 'pop' - valid_accounts.append('Popper password for %s://%s@%s' % \ + valid_accounts.append('Mailnag password for %s://%s@%s' % \ (protocol, acc.user, acc.server)) if gnomekeyring.list_item_ids_sync(defaultKeyring): # find and delete invalid entries @@ -889,7 +881,7 @@ class Keyring: item = gnomekeyring.item_get_info_sync(defaultKeyring, identity) displayNameDict[item.get_display_name()] = identity for key in displayNameDict.keys(): - if key[:19] == 'Popper password for' \ + if key[:19] == 'Mailnag password for' \ and key not in valid_accounts: gnomekeyring.item_delete_sync(defaultKeyring, displayNameDict[key]) @@ -897,8 +889,8 @@ class Keyring: def show_keyring_dialog(self): # dialog to get password to unlock keyring self.was_locked = True builder = gtk.Builder() - builder.set_translation_domain('popper_config') - builder.add_from_file("popper_keyring.glade") + builder.set_translation_domain('mailnag_config') + builder.add_from_file("mailnag_keyring.glade") builder.connect_signals({"gtk_main_quit" : self.exit_keyring_dialog, \ "on_button_cancel_clicked" : self.exit_keyring_dialog, \ "on_button_ok_clicked" : self.ok_keyring_dialog, \ @@ -920,8 +912,8 @@ class Keyring: def show_message(self, message): # dialog to show keyring messages builder = gtk.Builder() - builder.set_translation_domain('popper_config') - builder.add_from_file("popper_message.glade") + builder.set_translation_domain('mailnag_config') + builder.add_from_file("mailnag_message.glade") builder.connect_signals({"gtk_main_quit" : self.exit_message, \ "on_button_cancel_clicked" : self.exit_message, \ "on_button_ok_clicked" : self.ok_message}) @@ -1096,11 +1088,11 @@ class DesktopDisplay(gtk.Window): # displays a transparent frameless wi self.content = content # array of text lists - self.set_title('Popper Desktop Display') + self.set_title('Mailnag Desktop Display') self.set_app_paintable(True) # no window border self.set_decorated(False) self.set_position(gtk.WIN_POS_CENTER) - pixbuf = gtk.gdk.pixbuf_new_from_file('popper.png') # get icon from png + pixbuf = gtk.gdk.pixbuf_new_from_file('mailnag.png') # get icon from png self.set_icon(pixbuf) # set window icon pos_x = int(cfg.get('dd', 'pos_x')) pos_y = int(cfg.get('dd', 'pos_y')) @@ -1197,7 +1189,7 @@ class DesktopDisplay(gtk.Window): # displays a transparent frameless wi def read_config(): # read config file or create it cfg = ConfigParser.RawConfigParser() - cfg_file = user_folder + ".popper/popper.cfg" # folder: /home/user/.popper/popper.cfg + cfg_file = user_folder + ".mailnag/mailnag.cfg" # folder: /home/user/.mailnag/mailnag.cfg if not os.path.exists(cfg_file): # create a fresh config file print _("Config file does not exist, creating new one") cfg = set_default_config(cfg) # write default values to cfg @@ -1258,7 +1250,7 @@ def set_default_config(cfg): cfg.set('notify','text_one', 'You have a new mail.') cfg.set('notify','text_multi', 'You have %s new mails.') cfg.set('notify', 'playsound', 1) - cfg.set('notify', 'soundfile', 'popper.wav') + cfg.set('notify', 'soundfile', 'mailnag.wav') cfg.set('notify', 'speak', 0) try: cfg.add_section('dd') @@ -1303,17 +1295,17 @@ def update_desktop_file(headline): "Encoding=UTF-8\n" + \ "Name=" + headline + "\n" + \ "GenericName=Email Notifier\n" + \ - "X-GNOME-FullName=Popper Email Notifier\n" + \ + "X-GNOME-FullName=Mailnag Email Notifier\n" + \ "Comment=Get notified about new emails\n" + \ "Icon=applications-email-panel\n" + \ "Type=Application\n" + \ "Categories=GNOME;GTK;Email;Network;\n" + \ - "Exec=popper.py\n" + \ + "Exec=mailnag.py\n" + \ "StartupNotify=false\n" + \ "Terminal=false\n" + \ "X-Ayatana-Desktop-Shortcuts=Compose;Contacts\n" - desktop_file = user_folder + ".popper/popper.desktop" # folder: /home/user/.popper/popper.desktop + desktop_file = user_folder + ".mailnag/mailnag.desktop" # folder: /home/user/.mailnag/mailnag.desktop f = open(desktop_file,'w') f.write(desktop_content) f.close() @@ -1323,7 +1315,7 @@ def update_desktop_file(headline): def create_autostart(): curdir = os.getcwd() # get working directory - exec_file = os.path.join(curdir, "popper.sh") # path of the shell script to start popper.py + exec_file = os.path.join(curdir, "mailnag.sh") # path of the shell script to start mailnag.py content = "\n" + \ "[Desktop Entry]\n" + \ @@ -1332,13 +1324,13 @@ def create_autostart(): "Hidden=false\n" + \ "NoDisplay=false\n" + \ "X-GNOME-Autostart-enabled=true\n" + \ - "Name=Popper\n" + \ + "Name=Mailnag\n" + \ "Comment=Email notifier for the indicator menu" autostart_folder = "%s/.config/autostart/" % (user_folder) if not os.path.exists(autostart_folder): os.popen("mkdir -p " + autostart_folder) - autostart_file = autostart_folder + "popper.sh.desktop" + autostart_file = autostart_folder + "mailnag.sh.desktop" f = open(autostart_file, 'w') f.write(content) # create it f.close() @@ -1346,7 +1338,7 @@ def create_autostart(): def delete_autostart(): autostart_folder = "%s/.config/autostart/" % (user_folder) - autostart_file = autostart_folder + "popper.sh.desktop" + autostart_file = autostart_folder + "mailnag.sh.desktop" if os.path.exists(autostart_file): os.popen("rm " + autostart_file) # delete it @@ -1361,15 +1353,15 @@ def main(): locale.setlocale(locale.LC_ALL, '') # locale language, e.g.: de_CH.utf8 except locale.Error: locale.setlocale(locale.LC_ALL, 'en_US.utf8') # english for all unsupported locale languages - locale.bindtextdomain('popper_config', 'locale') - gettext.bindtextdomain('popper_config', 'locale') - gettext.textdomain('popper_config') + locale.bindtextdomain('mailnag_config', 'locale') + gettext.bindtextdomain('mailnag_config', 'locale') + gettext.textdomain('mailnag_config') _ = gettext.gettext user_folder = os.path.expanduser("~/") # folder: /home/user/ - popper_folder = user_folder + ".popper" # folder: /home/user/.popper - if not os.path.exists(popper_folder): - os.popen("mkdir -p " + popper_folder) # create: "/home/user/.popper" if not exists + mailnag_folder = user_folder + ".mailnag" # folder: /home/user/.mailnag + if not os.path.exists(mailnag_folder): + os.popen("mkdir -p " + mailnag_folder) # create: "/home/user/.mailnag" if not exists cfg = read_config() # get configurations keyring = Keyring() diff --git a/mailnag_config.sh b/mailnag_config.sh new file mode 100755 index 0000000..4d20363 --- /dev/null +++ b/mailnag_config.sh @@ -0,0 +1,21 @@ +#!/bin/bash +if [ ! -d ~/.mailnag ]; then + mkdir ~/.mailnag +fi +if [ -f ~/.mailnag/mailnag_config.log ]; then + rm ~/.mailnag/mailnag_config.log +fi +cd `dirname $0` +python mailnag_config.py >> ~/.mailnag/mailnag_config.log 2>&1 +if [ $? -eq 0 ]; then + # Restart mailnag.py + if [ -f ~/.mailnag/mailnag.pid ]; then + kill $(cat ~/.mailnag/mailnag.pid) + fi + if [ -f ~/.mailnag/mailnag.log ]; then + rm ~/.mailnag/mailnag.log + fi + python mailnag.py >> ~/.mailnag/mailnag.log 2>&1 & +else + echo mailnag-config discarded +fi diff --git a/popper_icon.png b/mailnag_icon.png similarity index 100% rename from popper_icon.png rename to mailnag_icon.png diff --git a/popper_keyring.glade b/mailnag_keyring.glade similarity index 97% rename from popper_keyring.glade rename to mailnag_keyring.glade index e1f8a48..9b75bc3 100644 --- a/popper_keyring.glade +++ b/mailnag_keyring.glade @@ -4,13 +4,13 @@ 5 - Popper + Mailnag True center 250 150 True - popper_icon.png + mailnag_icon.png dialog True diff --git a/popper_message.glade b/mailnag_message.glade similarity index 97% rename from popper_message.glade rename to mailnag_message.glade index 1601926..877ea33 100644 --- a/popper_message.glade +++ b/mailnag_message.glade @@ -4,7 +4,7 @@ 5 - Popper Message + Mailnag Message False center normal diff --git a/popper_changelog.txt b/popper_changelog.txt deleted file mode 100644 index f2e19bd..0000000 --- a/popper_changelog.txt +++ /dev/null @@ -1,333 +0,0 @@ -======================================================================== -Open Items -======================================================================== - -0.28 -- PPA - - - -Backlog ------------------------------------------------------------------------- -- PPA bauen (siehe: http://wiki.ubuntuusers.de/Launchpad/PPA) -> IRC -- Bug 684906: apply XDG standards -- show errors and warnings on the screen (not only in popper.log) (optional) -- Änderungswünsche: - 1. ich hätte gern die Möglichkeit Verbindungen ohne SSL zu verbieten - 2. die Abfragehäufigkeit sollte für jeden Mailaccount separat setzbar sein -- Momentan wird eine vorhandene Logdatei in popper.sh gelöscht. - Schöner wäre ein 'truncate --size 0', da dadurch ein 'tail -f' weiterlaufen würde. -- Derzeit wird das Logging einfach durch die Umleitung der Standardausgabe vorgenommen. - Wesentlich schöner wäre der Gebrauch des Moduls logging und die Konfigurationsmöglichkeit - eines Loglevels. Hierdurch ließen sich insbesondere viele zusätzliche Ausgaben im - Debug-Level aufnehmen, die derzeit nur stören würden. -- https://bugs.launchpad.net/bugs/712986 - Since most IMAP servers support IDLE protocol, it would be nice to have this support in popper. - IMAP IDLE is implemented in imaplib2 python module from Piers Lauder who is also the author of the original imaplib - http://sydney.edu.au/engineering/it/~piers/python/imaplib.html - There is a very short example at http://blog.timstoop.nl/2009/03/11/python-imap-idle-with-imaplib2/ - I'm willing to try to write a patch as soon as I have time. -- Mijobe: - DD erscheint nur auf dem virtuellen Desktop, der zufällig bei der ersten eintreffenden Mail aktiv ist. - Es sollte entweder auf allen virtuellen Desktops zu sehen sein, oder es sollte möglich sein ihm einen zuzuweisen. - Wenn ich alle Mails gelesen habe, verschwinden sie zudem nicht von sich aus vom Desktop. - - Mehr Kommandos für Menüeinträge: - - "pause/continue [Kontoname]" um Popper bzw ein Konto aussetzen zu lassen ohne Popper zu stoppen, - - einen optionalen Parameter "Kontoname" beim "check", "[de]activate blob/sound/desktop/scripts/filter" - um die einzelnen Funktionalitäten zu [de]aktivieren. - - Durch den Neuaufbau der Kontenmaske ist es relativ leicht geworden, POP/POPS/IMAP/IMAPS von einander - zu trennen und unterschiedliche Abfragehäufigkeiten einzuführen. -- Änderung for WorkingDirectory beim Aufruf von z.B. Thunderbird - -======================================================================== -DONE -======================================================================== - -Version 0.28 - 2011.04.08 -- Bug 752387: Popper doesn't show provider ... -> fixed - -Version 0.27 - 2011.04.05 -- continue if server does not deliver a message or msg -- Bug 735071: no new mails leads to error (Fix: Folderstatus 'OK'? Folderdata not None?) -- remove desktop display on headline click in message menu -- context menu on right-click in desktop display with internal (clear, exit, list, check) - or user commands (same as configured by user for message menu) -- replace newline ('\n') by space (' ') in subjects and real_sender -- internal command 'clear' destroys desktop display -- another correction of degenerated email headers ( ?==? to ?= =? ) -- changed default charset for decoding to 'latin-1' instead of 'utf-8' -- set user_path/user_folder to os.path.expanduser(... -- re-added missing popper_message.glade - -Version 0.26 - 2011.02.28 -- multiple accounts -- correct degenerated email headers -- delete obsolete entries in Keyring when Configurator is closed -- desktop display -- don't show removed emails again when 'remove_single_email' clicked -- accept email header keys (From, Date, Subject) also in lower case -- format_header for Subject rewritten (to solve the ä-Problem) -- bubble, sound, speach are now independent from each other - -Version 0.25 - 2011.01.24 -- improved update of old config files -- indirect addressing in Configurator -- Bug 694814: UTC time error fixed -- speaks notification text -- removed plausibility check of empty fields in first account row -- fixed error with "print %" in CR-ed line (popper.py line 155 und weitere) -- implemented "remove single email from indicator when clicked" in Configurator -- subprocess management to avoid zombies -- Popper and Popper_Config always started as background processes in shell scripts -- Popper_Config can be closed without doing anything (button: Cancel) -- Translations updated and corrected -- Wrote explanation about mandatory settings in help files -- Help files updated for all changes in this version -- fixed race condition: wrong sort order at first start -- avoid unnecessary keyring-outputs in logfile -- Bug 693546: Items stored and retrieved in the keyring are vague and can conflict -- Keyring migration from 0.24 - Keyring entries < 0.24 will be deleted -- Help file updated and corrected - -Version 0.24 - 2010.12.21 -- removed version migration code -- corrected line breaks in print strings (avoid unwanted spaces/tabs) -- translated keyring_message_dialog -- check for Internet connection in python.sh before launch popper -- try:except: reviewed -- checked time-delta calculation -> found no errors -- get rid of grey bubble in indicator menu -> check evolution.desktop -> does not work -- implement gnomekeyring: get_default_keyring_sync() to avoid problem with non existing 'login' keyring -- get rid of some try:except and own exception-prints in Keyring-Class -- long subject text not shown in notification bubble -> found no errors -- created class Mails and moved related functions in this class -- undone "if not firstcheck" in is_online() -- user_scripts implemented: on_email_clicked, on_account_clicked -- fix infos in Software Center -> don't know how, at least removed description from heading -- import existing email accounts from Keyring -- striped IMAP folder list (to eliminate imaplib.errors) - -Version 0.23 - 2010.11.21 -- removed old obfuscation error trapping -- code cleaned-up according PEP -- implement keyring (again) -- improved versioning -- migration from 0.22 to 0.23 config settings when started the first time -- created new tab in configurator for 'user scripts' -- 'scripts' coded in popper.py and popper_config.py -- filter implemented -- sort order fixed (caused by keyring-password-dialog) -- dialog for keyring messages - -Version 0.22 - 2010.10.29 -- subject_length not respected when 'show_sender = off' -- age of emails in counter spot -- replaced old obfuscation method -- info message to re-enter password(s) - -Version 0.21 - 2010.10.13 -- change rights on usr/share/popper and *.sh files to enable multiuser -- prevent duplicated Gmail emails caused by labels -- internationalization (supports german and english for all other languages) - -Version 0.20 - 2010.09.29 -- remove try from reminder.load() in popper.py after 0.19 -> no -- removed try for 'show_only_new' in configurator after 0.19 -- show Sender and Subject in notification when one new email comes in -- fix problem with 'de_CH', 'nsd_DE' -- clean-up configurator (tab: indicator) -- for IMAP use non_SSL if SSL does not work -- handle passwords as unicode -> no, works as designed even with strange chars -- IMAP.error -> is not caused by wrong folder parsing -- keep List filled after clear() when "show only new email" is set - -Version 0.19 - 2010.09.21 -- fixed bug in mail_count for IMAP accounts -- implemented 'show_only_new' - -Version 0.18 - 2010.09.12 -- subject text in summary window is not cut anymore -- take current time if time from email cannot be retrieved -- enhanced sound file (fades out) -- normalized datetime to enable sorting in summary window -- default sort order in summary window is: by date desc -- added lots of debug code to get_mail() -- prevent showing summary window with mails when it should be empty after click on Heading or Clear -- notification sequence changed to: Envelope -> Sound -> OSD -- how to sort a multi-array: sorted(rows, key=lambda rows: rows[3]) -- fixed: envelope not set to white when Headline clicked -- enabled multiuser: popper.cfg and popper.dat in /home/user/.popper/ -- providers in configurator can be switched on/off -- removed 'number_of_entries' from configurator -- reset envelope to white if all summaries are (0) - -Version 0.17 - 2010.09.06 -- summary list: columns resizable, window auto-resizes -- internal command 'list' to open a summary window for all providers -- different sort behaviour when popper.py is restarted after configurator -- summary number should only count unseen emails? No, should reflect inbox. - -Version 0.16 - 2010.08.24 -- write/delete popper.py's pid to file 'popper.pid' -- remove restart warning in popper_config -- hided 'max email entries' from configurator -- popper.dat not deleted after config changes anymore -- removed try/except for new fields in configurator -- process internal commands: clear, exit, check -- implement 'summarize by provider' -- configurator will restart popper.py on exit -- Konfigurator renamed to Configurator in popper_config.desktop -- debug code to find the strange value in 'response' from Gmail -- Show list of emails for summary accounts in separate dialog - -Version 0.15 - 2010.08.18 -- menu entries are not saved in popper.dat -- removed 'clear entries' because clearing does not work -- menu entry names and commands are configurable -- sort order (date, provider) added to configurator -- log file messages are indented to improve readability -- debug code is marked with #debug -- message append logic refactored -- clear indicator list on every check to avoid sort problems -- if POP3_SSL does not work POP3 is used -- 3 custom menu entries -- plausibility check for menu entries on exit -- fixed problem with 'not more than 7 messages in indicator menu' - -Version 0.14 - 2010.08.11 -- solved 'empty log' problem by: sys.stdout.flush -- path to soundfile in configurator and popper.py -- table of contents for help files -- file chooser for soundfile in configurator -- play soundfile in configurator -- menu entries as messages (experimental) -- replaced mplayer by aplay -- sort problem fixed by reversing message list (seems to be an error in the indicator menu) -- help adapted: soundfile, menu entries, SSL - -Version 0.13 - 2010.08.04 -- replaced ALL by UNSEEN for IMAP accounts -- trapped 'no subject' error (KeyError in dmail['Subject']) -- play sound on new emails -- remove/add standard indicator entries -> no, only info in help -- menu entries for: Clear, WriteEmail, ShowAddressBook -> does not work, disabled in Configurator -- help updated for: play sound, remove/add standard indicator entries -- build DEB - -Version 0.12 - 2010.07.17 -- code reviewed -- swap header_field_formating to a separate function -- always save popper.desktop when configurator is closed (to avoid async) -- 'clear on click' is 'on' as default -- put POP/IMAP selection in configurator -- check inconsistence of IMAP chkbox and server: not implemented -- show reboot info when popper_config terminates -- help updated -- bubble/window radiobox removed -- switched GUI position of sender-subject / subject-sender -- email body text removed -- made MailServer a class -- show full subject text in bubble -- created Mail class - -Version 0.11 - 2010.07.13 -- code reviewed -- fixed sort problem -- fixed problem with unsaved headline in popper.desktop, reason was a - different default entry in popper.desktop and popper.cfg -- IMAP support -- show bodytext in bubble causes decode error: trapped error, don't show body -- config GUI redesigned for IMAP support -- show folder list from IMAP server in test output -- http://www.doughellmann.com/PyMOTW/imaplib/ -- read IMAP Header, Body, Flags -- support IMAP folders -- update Help -- update Minihelp in Configurator - -Version 0.10 - 2010.07.06 -- Help in Configurator (english and german) -- Show Provider as prefix to message -- Headline instead of Provider -- check internet connection until we have one, then get pop connection -- fixed error in popper.sh for writing to popper.log -- support for SSL (Gmail) -- notify format implemented in Configurator (bubble/window) -- open help file depending on local language (english for unknown) -- handle failed provider access after second try -- popper_icon.png created -- improved error handling in get_mail() -- decode sender_real (Umlaute etc.) -- delete popper.dat when config is changed to avoid - that saved messages compromise changed settings - -Version 0.09 - 2010.06.29 -- improved password obfuscation -- use id to compare mails (id = user + UIDL) -- remember last session (store messages) -- support multiple email accounts -- check multi account field consistency in popper_config -- strip all multi account fields -- option 'clear indication after click' -- fill list from top and hide bottom entries if above limit -- change test in popper_config for multi accounts - -Version 0.08 - 2010.06.24 -- check if autostart file exists before it is deleted -- create .config/autostart folder if it does not exist -- remove keyring and initial sleep(20) -- create popper_config.sh -- keep mails in panel even if Provider is clicked -- rewrote email parser -- show part of email.payload - -Version 0.07 - 2010.06.22 -- changed pop3.retr to pop3.top in order to get just the header and to keep them unread on the mail server -- if connection fails, try again after 30 seconds before popper.py is terminated -- all config settings applied (except autostart) -- implemented create/delete of autostart entry - -Version 0.06 - 2010.06.21 -- convert header tags to lowercase in order to fetch independent of case -- do not un-green envelope when all messages are clicked -- add notify_text_one/multi to popper_config.py -- cleaned up settings in popper_config.py -- apllied settings in popper.py -- fixed "name = gtk.Buildable.get_name(widget)" -- don't forget to check 'danach' for Signal in Glade to avoid "GtkEntry - did not receive focus-out-event" - -Version 0.05 - 2010.06.20 -- Notification implemented -- Message list cleaned up (remove read mails from indicator list) -- 'Click on item' fixed -- Click logic for indicator entries: Header -> open Evolution, Message -> show details -- implemented keyring for popper and popper_settings - -Version 0.04 - 2010.06.02 -- use same names in popper for subject, sender, etc. -- modify popper.desktop (example: Name=GMX) -- trim subject and sender string -- fixed subject encoding problem (bytecode is not accepted by indicator) - -Version 0.03 - 2010.05.28 -- Sender format in popper_config -- Algorithm to extract sender name and address from 'From:' -- Plausibility checks in popper_config - -Version 0.02 - 2010.05.26 -- Popper_Settings implemented with Glade -- Testing of email connectivity in popper_config -- Indicator implemented - -Version 0.01 - 2010.05.21 -- analysis of how to use notification in Lucid: - http://roscidus.com/desktop/node/336 -- analysis of how to use the indicator in Lucid: - http://gnomejournal.org/article/67/an-introduction-to-the-message-indicator - https://wiki.ubuntu.com/MessagingMenu/ - http://www.jonobacon.org/2010/01/14/application-indicators-rocking-the-house/ -- project name: Popper, A new email indicator and notifier for POP3 accounts -- Reading/Writing of configuration file -- Try to get the emails from an POP3 account diff --git a/popper_config.desktop b/popper_config.desktop deleted file mode 100644 index 32e91be..0000000 --- a/popper_config.desktop +++ /dev/null @@ -1,17 +0,0 @@ - -[Desktop Entry] -Name=Popper Configurator -Name[de]=Popper Configurator -Name[de_CH]=Popper Configurator -Name[de_AT]=Popper Configurator -Comment=A notifier for new emails -Comment[de]=Ein Benachrichtiger für neue Emails -Comment[de_CH]=Ein Benachrichtiger für neue Emails -Comment[de_AT]=Ein Benachrichtiger für neue Emails -Exec=/usr/share/popper/popper_config.sh -Icon=/usr/share/popper/popper_icon.png -Terminal=false -Type=Application -Categories=Network; -StartupNotify=false - diff --git a/popper_config.sh b/popper_config.sh deleted file mode 100755 index 8afbb5a..0000000 --- a/popper_config.sh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/bash -if [ ! -d ~/.popper ]; then - mkdir ~/.popper -fi -if [ -f ~/.popper/popper_config.log ]; then - rm ~/.popper/popper_config.log -fi -cd `dirname $0` -python popper_config.py >> ~/.popper/popper_config.log 2>&1 -if [ $? -eq 0 ]; then - # Restart Popper.py - if [ -f ~/.popper/popper.pid ]; then - kill $(cat ~/.popper/popper.pid) - fi - if [ -f ~/.popper/popper.log ]; then - rm ~/.popper/popper.log - fi - python popper.py >> ~/.popper/popper.log 2>&1 & -else - echo Popper-Configurator discarded -fi diff --git a/popper_help_de.txt b/popper_help_de.txt deleted file mode 100644 index 8867b94..0000000 --- a/popper_help_de.txt +++ /dev/null @@ -1,621 +0,0 @@ -Inhalt -======================================================================== -1. Einleitung -2. Installation -3. Funktionsweise -4. Konfigurator - 4.1. Tab 'Allgemein' - 4.2. Tab 'Konten' - 4.3. Tab 'Indikator' - 4.4. Tab 'Hinweis' - 4.5. Tab 'Desktop' - 4.6. Tab 'Skript' - 4.7. Tab 'Filter' - 4.8. Tab 'Test' - 4.9. Tab 'Hilfe' - 4.10. Die Tasten 'Wiederherstellen', 'Abbrechen', 'Speichern & Beenden' -5. Benachrichtigungsmenü - 5.1. Änderungen vornehmen - 5.2. Evolution-spezifische Einträge - 5.3. Hinweise -6. Fehler, Fragen, Forum - - -1. Einleitung -======================================================================== -Popper ist eine Anwendung zur Benachrichtigung über neue Emails, die auf -einem oder mehreren POP3 oder IMAP Email Servern liegen. Die Information -über neue Emails erscheint im Benachrichtigungsmenü des Ubuntu Desktops. -Anwender werden durch Info-Blasen auf dem Desktop und den grünen Briefum- -schlag im Panel (beim Standardthema) über neue Emails informiert. Außerdem -ist die Anzeige direkt auf dem Desktop möglich (vgl. 4.5.). - -Die Anwendung besteht aus zwei Teilen. Mit dem Konfigurator (popper_config.py) -werden alle Einstellungen vorgenommen. Popper (popper.py) ist das -eigentliche Programm zur Überprüfung des Email-Servers und Anzeige neuer -Emails. Der Konfigurator hat eine grafische Benutzeroberfläche und wird -aus dem Menü Anwendungen->Internet->Popper Configurator gestartet. Popper -selbst läuft im Hintergrund und ist an den Einträgen im Benachrichtigungsmenü -und an den Info-Blasen bei neuen Emails zu erkennen. Außerdem weist der grüne -Briefumschlag (beim Standardthema) im Panel auf Neuzugänge hin. - -Der Konfigurator bietet sehr viele Einstellmöglichkeiten. Lassen Sie sich -davon nicht abschrecken. Die Standardeinstellungen sind für den normalen -Anwender ausreichend. Lediglich die Angaben zu den Email-Konten im Tab -'Konten' müssen korrekt sein. Alle anderen Einstellung können später bei -Bedarf vorgenommen werden. Beim Verständnis hilft das Lesen dieses Hilfe- -texts ungemein. - - -2. Installation -======================================================================== -Popper liegt als DEB-Archiv vor und wird beim Ausführen über das -Software-Center installiert. Das Konfigurationsprogramm erhält einen -Starter-Eintrag im Menü: Anwendungen->Internet->Popper Configurator. -Über das Software-Center oder die Paketverwaltung (Synaptik) kann das -Programm deinstalliert werden. Der Konfigurator erstellt bzw. entfernt -einen Eintrag in der Autostart-Liste. - - -3. Funktionsweise -======================================================================== -Popper liest in einstellbaren Zeitabständen die Emails aus dem Posteingang -eines oder mehrerer POP3 oder IMAP Email Server via SSL bzw. nicht über -SSL falls dies vom Server nicht unterstützt wird. Absender und Betreff -der Emails werden im Benachrichtigungsmenü aufgeführt. Die Anzahl neuer -Emails wird in einer Info-Blase dargestellt. Popper vergleicht Neueingänge -mit den bereits gemeldeten Emails und informiert nur über die tatsächlich -neuen Emails. - -Das Programm löscht keine Emails auf dem Server, sondern liest sie nur. -Das Abholen (Löschen) der Emails auf dem Server obliegt dem Email-Client -wie z.B. Evolution, Thunderbird usw. Popper kommuniziert nicht mit dem -Email-Client. - -Die Information über bereits gemeldete Emails kann über die Sitzung hinaus -behalten werden. Auf Wunsch speichert Popper diese Daten, sodass bei -einem Neustart des PCs diese Emails nicht mehr als 'neu' gemeldet werden. - -Wenn Popper alle n Minuten auf neue Emails prüft, geschieht das -folgendermaßen: Zuerst wird getestet, ob eine Internetverbindung -besteht. Ist dies nicht der Fall, so wird der Test alle 5 Sekunden -wiederholt. Falls die Verbindung zeitweilig unterbrochen ist, z.B. -beim Aufenthalt im Freien, kann dadurch die Verbindung von Popper -sobald wie möglich wieder hergestellt werden. Bei bestehender -Internetverbindung versucht Popper, den Email-Server zu erreichen. -Wenn dies nicht gelingt, erfolgt nach 30 Sekunden ein zweiter Versuch. -Falls dieser auch fehlschlägt, wird versucht den Server des nächsten -Email-Anbieters (falls vorhanden) zu erreichen. Sollte keiner der -Server erreicht werden können, wird die gesamte Prozedur beim nächsten -Prüfen (nach n Minuten) wiederholt. - - -4. Konfigurator -======================================================================== -Das Konfigurationsprogramm für Popper wird aus dem Menü Anwendungen-> -Internet->Popper Configurator aufgerufen. Es ist in mehrere Bereiche unter- -teilt, in denen Einstellungen zu den verschiedenen Funktionsbereichen von -Popper gemacht werden können. Die Bereiche werden durch Tabs am oberen -Fensterrand dargestellt. -Beim Beenden des Konfigurators wird die eigentliche Anwendung Popper mit -den neuen Einstellungen gestartet. Ein bereits laufender Popper-Prozess -wird zuerst beendet und dann neu gestartet. - - -4.1. Tab 'Allgemein' -======================================================================== -Checkbox: Starte Popper automatisch nach der Anmeldung -Mit diesem Schalter wird gesteuert, ob Popper beim Start des Computers -(also beim Start oder Neustart der Sitzung) automatisch gestartet wird. -Es wird ein Eintrag in der Autostart-Liste erzeugt bzw. entfernt. - - -4.2. Tab 'Konten' -======================================================================== -Hier können beliebig viele Email-Konten angegeben werden aus denen -Popper die Informationen über neue Emails holt. Auf der linken Seite -befindet sich die Liste aller Konten; auf der rechten Seite stehen die -Einstellmöglichkeiten für das ausgewählte Konto. - -Kontenliste (auf der linken Seite) - -Checkbox: An -Mit diesem Schalter können Email-Konten von der Abfrage ein- bzw. -ausgeschlossen werden. Man kann alle Email-Konten eintragen und durch -diesen Schalter nach Bedarf bestimmte davon abfragen lassen. - -Textfeld: Name -Hier wird der Name des Kontos angezeigt, z.B.: GMX, Gmail. -Der Text wird nur zur Anzeige verwendet und nicht für die Verbindung -zum Email-Anbieter verwendet. Der Name kann auf der rechten Seite -geändert werden (siehe unten). - -Schaltfläche: Import -Mit dieser Funktion wird der Ubuntu Schlüsselbund nach bestehenden -Email-Konten durchsucht. Bei jedem gefundenen Konto kann gewählt werden, -ob es in Poppers Email-Liste aufgenommen werden soll. Wählt man ein Konto -aus, so sollte auf jeden Fall dessen Name geändert werden und alle -importierten Einträge auf Korrektheit überprüft werden. Möchte man diese -tatsächlich nutzen, so muss die Checkbox 'An' eingeschaltet werden. - -Schaltfläche: Neu -Hiermit wird ein neues Konto angelegt. Der Name und die Mindestangaben -(Server, Anwender, Passwort) (s.u.) müssen eingegeben werden. Ausserdem -muss die Checkbox 'An' eingeschaltet werden falls das Konto von Popper -abgefragt werden soll. - -Schaltfläche: Löschen -Das in der Liste ausgewählte Konto wird (auf Nachfrage) gelöscht. - - -Detaileinstellungen (auf der rechten Seite) - -Textfeld: Name -Hier wird der Name des Kontos eingegeben, z.B.: GMX, Gmail. -Der Text wird nur zur Anzeige verwendet und nicht für die Verbindung -zum Email-Anbieter verwendet. - -Textfeld: Server -Das ist der Name des Posteingangsservers des Email-Anbieters, z.B.: -'pop.gmx.net' oder 'imap.googlemail.com' Dieser Name wird für die -Verbindung zum Email-Anbieter verwendet. - -Textfeld: Anwender -Hier wird der Name des Benutzerkontos beim Email-Anbieter eingetragen. -Dieser ist in der Regel identisch mit der Email-Adresse, z.B.: -'hein.mueck@gmx.net' - -Textfeld: Passwort -Zu jedem Benutzerkonto gehört ein Passwort. Die Buchstaben des Passworts -werden in diesem Feld durch Punkte dargestellt. Passwörter werden von -Popper mit dem Gnome-Schlüsselbund verwaltet. Bei Ersteingabe eines Kontos -im Konfigurator oder bei einer Änderung des Passwortes eines bestehenden -Kontos werden die entsprechenden Daten im Schlüsselbund gespeichert. Auf -diese Daten greift Popper später bei der Prüfung auf neue Emails zurück. -Hierfür muss der Schlüsselbund bei jedem Sitzungsstart eines Benutzers ent- -sperrt werden, falls das Schlüsselbund-Passwort nicht auf LEER gesetzt wurde. -Wer dies machen will und/oder sich weiter mit dem Schlüsselbund beschäftigen -möchte sollte einen Blick auf das Programm "Seahorse" bzw. dessen Dokumen- -tation werfen. "Seahorse" ist in Ubuntu erreichbar über das Menü System-> -Einstellungen->Passwörter und Verschlüsselung. - -Checkbox: IMAP -Ein Email-Konto kann entweder über POP oder IMAP angesprochen werden. -In der Regel kann dies aus dem Servernamen abgelesen werden, z.B.: -'pop.gmx.net'. Für den Typ 'IMAP' muss diese Checkbox eingeschaltet -werden und für den Typ 'POP' ausgeschaltet werden. Falls der Typ unklar -ist, empfiehlt es sich die Box ausgeschaltet zu lassen. - -Textfeld: IMAP Verzeichnisse -Bei einem IMAP Email-Konto kann hier optional die Liste von Verzeichnissen -angegeben werden, aus denen Popper die Informationen über neue Emails -abholt. Mehrere Einträge müssen mit Komma getrennt werden. Falls das -Feld leer bleibt, wird immer 'INBOX' als Verzeichnis angenommen. Wenn -Verzeichnisse angegeben werden, muss 'INBOX' explizit eingegeben werden. -Beim Anbieter 'Gmail' gibt es statt der Verzeichnisse sogenannte Labels. -Im Unterschied zu den Verzeichnissen kann eine Email mehrmals unter -verschiedenen Labels erscheinen. Popper verhindert in diesem Fall, dass -die selbe Email mehrmals angezeigt wird. - -Textfeld: Port -Falls ein spezieller Port für die Serververbindung verwendet werden soll, -kann dessen Nummer hier eingegeben werden. Im Normalfall bleibt dieses -Feld leer. - -Textfeld: Abfragehäufigkeit (gilt für alle Konten) -Popper prüft in regelmäßigen Abständen, ob sich neue Emails im -Posteingang des Email-Servers befinden bzw. ob dort Emails gelöscht -wurden. Die Zahl 'Abfragehäufigkeit' gibt an, nach wie vielen Minuten sich -die Abfrage wiederholt. Der Maximalwert beträgt 1440 (entspricht -24 Stunden), der Minimalwert liegt bei 1 Minute. Manche Anbieter -verhindern ein zu häufiges Abfragen des Posteingangs (z.B. 15 Min. bei -Web.de); das ist bei der Eingabe des Wertes zu berücksichtigen. - -Checkbox: Einmalig prüfen (gilt für alle Konten) -Normalerweise prüft Popper wiederholt den Posteingang des Email-Servers. -Wenn diese Checkbox eingeschaltet ist, prüft Popper den Posteingang -nur ein einziges Mal und beendet sich dann. Diese Einstellung ist dann -sinnvoll, wenn man nur beim Start des Computers über neue Emails -informiert werden möchte oder verhindern will, dass Popper die ganze -Zeit über im Hintergrund läuft. - - -4.3. Tab 'Indikator' -======================================================================== -Textfeld: Überschrift -Dieser Text wird als Überschrift im Benachrichtigungsmenü verwendet. - -Textfeld: Kommando für Überschrift -Hier kann ein Kommando eingegeben werden, das bei einem Klick auf -die Überschrift ausgeführt wird. Sinnvollerweise ist dies der Aufruf -eines Email-Client Programms wie z.B. Evolution oder Thunderbird. -Es ist wichtig zu verstehen, dass Popper keinerlei Informationen mit -diesen Programmen austauscht. Popper weiß nicht, was der Email-Client -mit den Emails macht. Um das korrekte Kommando für dieses Feld zu finden -empfiehlt es sich, den Start des Email-Clients im Terminal zu probieren -oder beim Menü-Eintrag von Ubuntu nachzusehen. -Das Kommando für die Überschrift kann auch bei Klick auf das 'Desktop -Display' verwendet werden (vgl. 4.5.). - -Checkbox: Zeige Absender -Stellt ein, ob der Absender einer Email sichtbar ist. - -Auswahl: Hein Mück; hein.mueck@gmx.de -Einstellung ob der natürliche Name oder die Email Adresse gezeigt wird. -Sollte eine Email keinen natürlichen Namen haben, wird immer die -Email Adresse verwendet. - -Checkbox: Zeige Betreff -Stellt ein, ob der Betreff der Email sichtbar ist. - -Textfeld: Max. Betrefflänge -Hiermit kann die Länge des Email-Eintrags im Benachrichtigungsmenü -beeinflusst werden. Die Länge gibt an, beim wievielten Buchstaben der -Email-Betreff abgeschnitten wird. Abgeschnittene Betreffs werden durch -drei Punkte am Ende gekennzeichnet. Diese Längeneinstellung wird auch -bei der separaten Email-Liste (Summarize by provider) berücksichtigt. - -Auswahl: Absender-Betreff, Betreff-Absender -Darstellung einer Zeile im Benachrichtigungsmenü. Entweder wird zuerst -der Betreff und dann der Absender angezeigt oder umgekehrt. - -Checkbox: Zeige Anbieter vor der Email -Bei mehreren Email-Konten kann es hilfreich sein, den Namen des -Anbieters vor dem Email-Eintrag im Benachrichtigungsmenü anzuzeigen. -Dieser Schalter bestimmt, ob der Anbieter angezeigt wird oder nicht. - -Auswahl: Sortiere nach Datum, Sammelliste pro Anbieter -Mit dieser Auswahl wird eingestellt ob die Einträge im Benachrichtigungs- -menü nach Datum oder nach Email-Anbieter sortiert werden. Bei der Sortierung -nach Datum werden alle Emails (unabhängig von welchem Konto sie kommen) -nach ihrem Eingangsdatum sortiert. Dadurch erscheinen die neusten Emails -ganz oben in der Benachrichtigungsliste. -Popper zeigt das Alter der Emails ganz rechts in einem Kreis an. Das Alter -wird entweder in Sekunden (s), Minuten (m), Stunden (h), Tagen (d), -Wochen (w), Monaten (M) oder Jahren (Y) dargestellt. -Beim Summieren nach Provider werden die neuen Emails nicht mehr einzel -ausgelistet sonder nur der Name des Providers mit der Anzahl neuer Emails -daneben angezeigt. Durch einen Klick auf den Provider öffnet sich ein -Fenster in dem die gesamte Liste der Emails dieses Providers angezeigt -werden. - -Checkbox: Speichere letzte Sitzung -Wenn diese Option ausgeschaltet ist, wird Popper bei jedem Neustart -den kompletten Posteingang des Servers als 'neue Email' melden, auch -wenn diese bereits vorher als 'neu' gemeldet wurden. Ist diese Option -eingeschaltet, merkt sich Popper den aktuellen Meldestatus und wird -bei einem Neustart keine Emails als 'neu' melden, die bereits vorher -gemeldet wurden. - -Checkbox: Einzelnen Email Eintrag mit Klick entfernen -Mit dieser Option wird erreicht, dass ein Email Eintrag im Indikatormenü -durch einen Mausklick entfernt werden kann. Es wird keine weitere Aktion -ausgeführt, wodurch diese Einstellung nur in Verbindung mit einem Skript -Sinn macht. Durch Aktivieren eines eigenen Skripts für das Ereignis -'Anklicken eines Emails im Indikatormenü' kann eine sinnvolle Aktion -ausgeführt werden. (Diese Funktion ist experimentell.) - - -Checkbox: Zeige nur neue Emails -Diese Option ist für Anwender gedacht, die ihren Posteingang auf dem -Email-Server nicht automatisch vom Emai-Client löschen lassen bzw. für -Anwender, die über einen Web-Browser auf ihre Emails zugreifen und den -Posteingang nicht konsequent leeren. Normalerweise spiegelt Popper bei -jedem Prüfen den Posteingang und führt alle Emails im Indicator-Menü auf. -Wenn diese Option eingeschaltet ist, zeigt Popper nur die neuen Emails -im Indicator-Menü (entweder als Eintrag oder als Zähler). Sobald auf die -Überschrift im Menü oder auf die Funktion 'clear' (siehe 'Spezielle -Kommandos') geklickt wird, werden alle Emails als 'gesehen' markiert -und nicht erneut im Indicator-Menü dargestellt. Die Sammelanzeigen -(entweder über die Funktion 'list' oder über Klick auf einen Sammel- -eintrag (z.B. GMX(3)) zeigen jedoch nach wie vor alle Emails des jeweiligen -Posteingangs an. So kann es z.B. sein, dass trotz GMX(3) sieben Emails -im Sammelfenster angezeigt werden. GMX(3) bedeutet, es sind 3 neue Emails -im GMX Posteingang obwohl dort sieben Emails liegen. Es gibt keine -Möglichkeit einzelne Emails im Indicator-Menü als 'gesehen' zu markieren. - -Checkbox: Emails aus Liste entfernen bei Klick auf Überschrift -Falls der Email-Client (Evolution, Thunderbird usw.) so eingestellt ist, -dass neue Emails beim Abholen aus dem Posteingang des Servers gelöscht -werden, empfiehlt es sich, diese Option einzuschalten. Dann werden -alle Email-Einträge im Benachrichtigungsmenü sofort entfernt und der -grüne Briefumschlag (beim Standardthema) wieder auf 'neutral' gestellt. -Wenn diese Option ausgeschaltet ist, wird das Benachrichtigungsmenü erst -beim nächsten Prüfen des Posteingangs auf dem Server durch Popper -aktualisiert. - -Menüeinträge -Es können drei Menüeinträge eingestellt werden. Diese erscheinen -zuoberst im Benachrichtigungsmenü vor den Emails. Für jedem Menüpunkt -kann eine Funktion eingegeben werden die nach einem Klick auf den -Menüpunkt ausgeführt wird. Diese Menüeinträge können auch per Rechts- -klick auf das 'Desktop Display' erreicht werden (vgl. 4.5.). - -Checkbox ganz links -Mit dieser Option kann bestimmt werden, ob der betreffende Menüeintrag -im Benachrichtigungsmenü angezeigt wird. - -Textfeld links 'Menüeinträge' -Enthält den Namen des Menüeintrags wie er im Benachrichtigungsmenü -angezeigt werden soll. Die Standardeinstellungen lauten: -'Write new email' und 'Open address book'. Diese Texte zum 'Schreiben -einer neuen Email' bzw. 'Öffnen des Adressbuches' können beliebig -angepasst werden. - -Textfeld rechts 'Kommandos für Menüeinträge' -Enthält das zugehörige Kommando für diesen Menüeintrag. Die Standard- -einstellungen lauten: 'evolution mailto:' und 'evolution -c contacts'. -Die Kommandos beziehen sich auf den Email-Client 'Evolution'; für -andere Email-Clients wie z.B. Thunderbird müssen die Kommandos ent- -sprechend angepasst werden (hier hilft eine Suche im Internet). - -Spezielle Kommandos -In das 'Textfeld rechts' können folgende Sonderkommandos eingegeben -werden: -'exit' Das Programm Popper wird beendet -'clear' Die Liste der Emails im Benachrichtigungsmenü wird gelöscht -'check' Es wird sofort auf neue Emails geprüft -'list' Es wird ein Fenster mit allen neuen Emails angezeigt - Siehe auch: "Summarize by provider" - - -4.4. Tab 'Hinweis' -======================================================================== -Checkbox: Zeige Info-Blase bei neuen Emails -Wenn diese Option eingeschaltet ist, macht Popper bei neuen Emails -durch eine Meldung in Form einer dunklen Blase am rechten oberen -Bildschirmrand darauf aufmerksam. Diese Meldung wird ca. 10 Sekunden -lang angezeigt und verschwindet dann automatisch. Schaltet man diese -Option aus, so wird keine Meldung angezeigt. Neue Emails kann man -jetzt nur noch am grünen Briefumschlag (beim Standardthema) im Panel -erkennen. - -Textfeld: Text für eine neue Email -Dieser Text wird gemeldet, falls eine neue Email eingetroffen ist. -Zusätzlich wird auch der Absender und der Betreff der Email angezeigt. - -Textfeld: Text für mehrere neue Emails -Dieser Text wird gemeldet, falls mehrere neue Emails vorliegen. - -Checkbox: Klang für neue Emails abspielen -Wenn diese Option eingeschaltet ist, wird beim Eintreffen neuer Emails -eine kurze Melodie abgespielt. Die Musikdatei heißt 'popper.wav' und -sie wird mit dem in Ubuntu vorinstallierten Programm 'aplay' abgespielt. - -Textfeld: Klangdatei -Hier kann der Name bzw. Pfad zu einer Musikdatei eingegeben werden die -beim Eintreffen neuer Emails abgespielt wird. Zum Abspielen der Datei -wird das Programm 'aplay' verwendet. Es werden Dateien im Format 'wav' -unterstützt (Achtung: kein 'mp3'). -Mit der Schaltfläche 'Auswählen' rechts neben dem Textfeld kann man einen -Dateidialog anzeigen aus dem eine Musikdatei ausgewählt werden kann. -Als Standard wird das Verzeichnis der OpenOffice.org Musikbibliothek -angezeigt. - -Schaltfläche: Klang abspielen -Zum Testen der Musikdatei kann die Datei aus dem Textfeld 'Klangdatei' -mit dieser Schaltfläche abgespielt werden. Wenn die Option 'Hinweistext -sprechen' eingeschaltet ist, wird zu Testzwecken der 'Text für eine neue -Email' gesprochen. Dies geschieht nachdem die Klangdatei abgespielt wurde. - -Checkbox: Hinweistext sprechen -Wenn diese Option eingeschaltet ist, wird der Hinweistext beim Eingang -einer oder mehrerer Emails gesprochen. Dies geschieht nach dem Abspielen -der Klangdatei. - - -4.5. Tab 'Desktop' -======================================================================== -Das 'Desktop Display' ist eine alternative Methode um neue Emails direkt -auf dem Hintergrundbild anzuzeigen. Dazu wird ein rahmenloses und trans- -parentes Fenster verwendet. Es kann in der Grösse und Position beliebig -angepasst werden. Neue Emails werden mit Absender, Datum und Betreff -angezeigt. Die Zeilenlänge und die Anzahl der Emails hängt von den -Dimensionen des Fensters ab (Breite, Höhe). - -Checkbox: Desktop Display einschalten -Regelt, ob das Display angezeigt wird oder nicht. - -Textfeld: Display Position (x, y) -Hier kann die absolute Position für die linke obere Ecke des Displays -(in Pixeln) angegeben werden. (0, 0) befindet sich ganz links oben. -x ist der horizontale Wert (von links nach rechts) und y der vertikale -Wert (von oben nach unten). Falls die maximalen Werte des Bildschirms -überschritten werden, ist das Display nicht zu sehen. - -Textfeld: Display Grösse (Breite, Höhe) -Dies sind die Abmessungen des Display Fensters. 'Breite' gibt die hori- -zontale Ausdehnung in Pixeln an und 'Höhe' die vertikale Ausdehnung. Die -Display Grösse wird ausserdem für die Berechnung von Textzeilenenden und -die Anzahl dargestellter Email Einträge verwendet. Abgeschnittene Text- -zeilen bzw. unvollständige Email Listen werden durch '...' angezeigt. - -Hintergrundfarbe und Transparenz -Ein Klick auf den Schalter 'Hintergrundfarbe' öffnet einen Dialog zur -Auswahl der Displayfarbe. Ein Transparenzwert von 0% bedeutet keine -Transparenz während ein Wert von 100% für vollständige Durchsichtigkeit -steht. Die optimale Einstellung hängt von der Farbe des Hintergrundbildes -ab: einfach ausprobieren. -ACHTUNG: Bei vollständiger Transparenz kann es passieren, das man aus Versehen -in den unsichtbaren Bereich des Desktop Displays klickt, wodurch das konfigurierte -Verhalten ('Schliessen', Kommandostart für Überschrift) bei einem solchen Klick -ausgelöst wird (s.u.). - -Schriftfarbe und Art -Hiermit kann die Textfarbe, Schriftart und Schriftgrösse eingestellt -werden. Die optimale Textfarbe hängt von der Farbe des Hintergrundbildes -ab: einfach ausprobieren. - -Checkboxen: Bei Klick auf Desktop Display -Diese Checkboxen regeln, was bei einem Klick auf das Display passiert. -'Schliessen' schaltet das Display aus, löscht jedoch nicht die Emails -aus dem Indikator Menü. 'Starte Kommando für Überschrift' führt das -Kommando aus, welches im Tab 'Indikator' bei 'Kommando für Überschrift' -eingegeben wurde. Ausserdem werden die Emails aus dem Indikator Menü -gelöscht und der Briefumschlag zurückgesetzt. Hiermit kann z.B. ein -Email-Programm aufgerufen werden. - -Schaltfläche: Vorschau (an/aus) -Mit diesem Knopf kann die Vorschau des Desktop Displays an- bzw. ausge- -schaltet werden. Die Funktionen von 'bei Klick auf Desktop Display' -funktionieren in der Vorschau nicht. In der Vorschau wird nur Beispieltext -angezeigt jedoch keine echten Email-Texte. - -Die Menüeinträge, welche für das Benachrichtigungsmenü konfiguriert wurden -(vgl. 4.3.), können im Desktop Display durch Klicken der rechten Maustaste -ebenfalls angezeigt und gestartet werden. - -4.6. Tab 'Skript' -======================================================================== -Hier kann der Aufruf von eigenen Skripten eingestellt werden. Diese -Skripte werden ausgeführt wenn ein bestimmtes Ereignis in Popper eintritt. - -Folgende Ereignisse werden unterstützt: -- Das Eintreffen neuer Emails -- Das Eintreffen keiner neuen Emails -- Das Anklicken eines Emails im Indikatormenü -- Das Anklicken eines Sammeleintrags im Indikatormenü - -Mit den Checkboxen kann das Abfragen dieser Ereignisse ein- bzw. ausge- -schaltet werden. Wenn eine Checkbox eingeschaltet ist, muss im Textfeld -daneben ein Kommando oder der Name eines Shellskripts eingetragen sein. -Die Schaltfläche rechts neben dem Textfeld öffnet einen Dialog für die -Dateiauswahl. Als Standard wird das Verzeichnis /home/user/.popper -angeboten. Selbstverständlich kann sich das Shell Skript in einem -beliebigen Verzeichnis befinden. Es ist zu beachten, dass das Skript -ausführbar sein muss (das kann bei den Dateirechten eingestellt werden). - -Beim Skriptaufruf für das Ereignis 'Anklicken eines Emails' werden die -Parameter 'Absender, Datum/Zeit, Betreff' an das Skript als drei -Argumente übergeben und können dort nach Belieben benutzt werden. - -Beim Skriptaufruf für das Ereignis 'Anklicken eines Sammeleintrags' werden -die Parameter 'Kontoname, Anzahl Emails' an das Skript als zwei Argumente -übergeben und können dort nach Belieben benutzt werden. - - -4.7. Tab 'Filter' -======================================================================== -Mit Hilfe des Filters können unerwünschte Emails von der Anzeige ausge- -schlossen werden. Mit der Checkbox 'Filter anwenden' kann die Funktion -ein- bzw. ausgeschaltet werden. Im Filtertext können beliebig viele -Begriffe stehen die durch Komma getrennt werden müssen. Zeilenumbrüche -und Leerzeichen sind erlaubt. Beim Eintreffen neuer Emails wird der -Absender und Betreff eines jeden Emails mit den Filterbegriffen verglichen. -Falls ein Filterbegriff im Betreff enthalten ist, wird diese Email für die -Anzeige in Popper nicht berücksichtigt. Gross/Kleinschreibung wird nicht -berücksichtigt. -ACHTUNG: diese Filterfunktion hat keinen Einfluss auf andere Email -Programme wie Evolution oder Thunderbird. - - -4.8. Tab 'Test' -======================================================================== -Mit der Schaltfläche 'Teste Email Verbindung' kann überprüft werden, -ob eine Verbindung zum Email-Server hergestellt werden kann. Bei -mehreren Email-Konten werden diese alle getestet. Im Textfeld unterhalb -des Schalters wird das Testergebnis ausgegeben; es ist selbsterklärend. - -Sollte die Verbindung fehlschlagen, können folgende Punkte geprüft -werden: -- Schreibfehler bei: Server, User, Password -- Besteht überhaupt eine Verbindung zum Internet? -- Blockade durch den Email-Anbieter bei zu häufigem Abfragen - -Dieser Test sollte immer durchgeführt werden, nachdem die Einträge in -den Felder: Server, User, Password geändert wurden und bevor Popper -gestartet wird. Wenn der Test fehlschlägt, wird auch Popper nicht -funktionieren. - - -4.9. Tab 'Hilfe' -======================================================================== -Es wird dieser Hilfetext angezeigt. Die Sprache der Hilfe hängt von -der Ländereinstellung des Computers ab. Zurzeit wird 'deutsch' -unterstützt bzw. 'englisch' für alle anderssprachigen Länder. - - -4.10. Die Tasten 'Wiederherstellen', 'Abbrechen', 'Speichern & Beenden' -======================================================================== -Im unteren Fensterbereich befinden sich drei Schaltflächen. -Mit 'Speichern & Beenden' werden die aktuellen Einstellungen gespeichert und -das Konfigurationsprogramm von Popper wird verlassen. Anschliessend wird -das Programm Popper selbst gestartet. Falls es schon läuft, wird es -zuerst beendet und dann neu gestartet. Dadurch werden die veränderten -Einstellungen sofort wirksam. Ein Neustarten des Computers ist nicht -notwendig. - -Hat man sich beim Eintragen der Einstellungen vertan, so kann mit der -Taste 'Wiederherstellen' der letzte gespeicherte Zustand wieder hergestellt -werden. - -Die Schaltfläche 'Abbrechen' ist mit Vorsicht zu verwenden. Sie führt zu -einem sofortigen Programmabbruch ohne weitere Aktionen. Es werden keine -Änderungen an den Einstellungen gespeichert. Popper selbst wird nicht -unmittelbar nach dem Verlassen des Konfigurators gestartet. - - -5. Benachrichtigungsmenü -======================================================================== -Bei einer Standardinstallation von Ubuntu befinden sich im Benachrich- -tigungsmenü die Einträge: Chat, E-Mail und Nachrichten. Diese starten -jeweils das entsprechende Standardprogramm. - - -5.1. Änderungen vornehmen -======================================================================== -Wer einen dieser Einträge nicht benötigt, weil man das Programm nicht -verwendet oder weil 'E-Mail' durch Popper ersetzt wurde, kann das Menü -anpassen. - -Dazu muss man im Verzeichnis /usr/share/indicators/messages/applications/ -die entsprechende Datei entfernen. Im Verzeichnis gibt es für jeden Eintrag -eine Datei: -- empathy für Chat -- evolution für E-Mail -- gwibber für Nachrichten - -Die Dateien enthalten jeweils einen Verweis auf den Starter für die -Anwendung, der im Verzeichnis /usr/share/applications/ liegt. - - -5.2. Evolution-spezifische Einträge -======================================================================== -Sofern evolution eingerichtet wurde, kommen zu dem Eintrag E-Mail noch -zwei weitere hinzu: -- Neue Nachricht verfassen -- Kontakte - -Für diese Einträge gibt es keine eigene Datei im Verzeichnis -/usr/share/indicators/messages/applications/ Stattdessen sorgt der -Starter von Evolution für diese Einträge. Möchte man sie entfernen, muss -der Starter angepasst werden. Dazu öffnet man diesen mit einem -Texteditor und entfernt folgendes: -- die Zeile 'X-Ayatana-Desktop-Shortcuts=Compose;Contacts' -- die Abschnitte [Compose Shortcut Group] und [Contacts Shortcut Group] -Anschließend speichert man die Änderungen. - - -5.3. Hinweise -======================================================================== -Es empfiehlt sich die Datei(en) nicht zu löschen oder zu ändern, sondern -an einen anderen Ort eine Kopie anzulegen. Dann können die Anpassungen -später wieder rückgängig machen. - -Für Dateioperationen in den Verzeichnissen /usr/share/applications/ und -/usr/share/indicators/messages/applications/ werden Root Rechte (sudo) -benötigt. - -Die Änderungen am Menü werden eventuell erst nach einem Neustart wirksam. - - -6. Fehler, Fragen, Forum -======================================================================== -Fehler bitte hier melden (englisch): https://bugs.launchpad.net/popper -Fragen bitte hier stellen (englisch): https://answers.launchpad.net/popper -Anforderungen und Diskussionen finden im Forum statt (deutsch): -http://forum.ubuntuusers.de/topic/allgemeiner-email-benachrichtiger - - -======================================================================== -Ende der Hilfe diff --git a/popper_help_en.txt b/popper_help_en.txt deleted file mode 100644 index 90a2358..0000000 --- a/popper_help_en.txt +++ /dev/null @@ -1,567 +0,0 @@ -Table of contents -======================================================================== -1. Introduction -2. Installation -3. How it works -4. Configurator - 4.1. Tab 'General' - 4.2. Tab 'Accounts' - 4.3. Tab 'Indicate' - 4.4. Tab 'Notify' - 4.5. Tab 'Desktop' - 4.6. Tab 'Script' - 4.7. Tab 'Filter' - 4.8. Tab 'Test' - 4.9. Tab 'Help' - 4.10. Buttons 'Restore', 'Cancel' and 'Save & Exit' -5. Indicator menu - 5.1. Making Changes - 5.2. Evolution-specific entries - 5.3. Remarks -6. Bugs, Questions, Forum - - -1. Introduction -======================================================================== -Popper is an application to notify about new emails from one or more -POP3 or IMAP email servers. New emails are notified on the Ubuntu Gnome -Desktop in the indicator menu on the panel and by means of notification -bubbles. Emails can also be displayed directly on the desktop. - -It consists of two parts. The configurator (popper_config.py) let you -make all settings that are used by Popper (popper.py) itself. It comes -with a graphical user interface and is started from menu: applications-> -internet->popper configurator. Popper itself is a background application -that just shows up in the indicator menu and with notification bubbles -for new emails. - -The configurator provides a lot of settings. Don't be discouraged, you -only need to set correct email account entries. All other options can be -done later on demand. Please read this help text to understand the -meaning of the advanced settings. - - -2. Installation -======================================================================== -Popper is available as a DEB archive and is installed with the Debian- -Installer (gdebi). After successful installation you will find a new -entry in menu: applications->internet named 'Popper Configurator' which -starts the configurator. The installer also creates or removes an entry -to your autostart list. - - -3. How it works -======================================================================== -Popper reads in defined intervals the inbox of your POP3 or IMAP email -server via SSL or non SSL if the server does not support SSL. -Sender and subject are listed in the indicator menu. -The number of new emails shows up in the notification bubble. Popper -compares new entries with emails that were already notified and informs -only about the new ones. - -The application does not delete any emails from your server, it only -reads them. Deleting the entries of your inbox remains a task of your -email client, e.g. Evolution, Thunderbird, etc. Popper does not -communicate with your email client, it only knows the inbox of your -server. - -Information about already notified emails can be kept beyond a computer -session. Optionally Popper saves your messages and does not notify them -as 'new' when you start your PC next time. - -Popper checks your inbox every n minutes. How does this work? First -Popper check for an internet connection. Without a connection the -check is repeated every 5 seconds. This ensures that your computer is -re-connected in case you were temporarily offline, e.g. you lost WLAN -connection because you are roaming. If you are online, Popper tries to -connect to your email server. If it fails, the program will try again -after 30 seconds. In case it fails again, Popper connects the next -email server in the list (if any at all). If no server could be -reached, Popper repeats the whole procedure after n minutes when it -makes its next check. - - -4. Configurator -======================================================================== -The Popper Configurator is started from menu: applications->internet-> -popper configurator. It contains different areas for the settings which -are arranged in tabs at the upper window edge. -If you close the Configurator it will start Popper itself. If Popper is -already running, it will be terminated and then restarted. - - -4.1. Tab 'General' -======================================================================== -Checkbox: Start Popper automatically after login -If this one is checked, an entry in your autostart folder will be -created. When you start your computer or restart the session, Popper -is started automatically. Unchecking this option will delete the -autostart entry. - - -4.2. Tab 'Accounts' -======================================================================== -Enter the email accounts that you want to be checked for new emails. On -the left side you see the list of your accounts. The right side lets you -enter details for a selected account. - -Account List (left side) - -Checkbox: On -Switch this checkbox to include or exclude email accounts from beeing -retrieved from the server. You can enter all your email accounts and -switch them on or off on demand. - -Text: Name -The name of your email provider, e.g.: GMX, Gmail. -This text is only used for displaying the provider, it is not used -for the connection to your email server. The name can be changed on the -right side (see below). - -Button: Import -This feature imports existing email accounts from Ubuntu Keyring. For -each detected account you will be asked to add it to the account list. -For each new account you should check if the imported fields are -correct, activate the account (switch 'on') and change the imported -acccount name to something meaningfull. - -Button: Add -Click this button to add a new account. The name and the other mandatory -fields (server, user, password) (see below) must be entered. Enable the -checkbox 'On' if you want Popper to check this email account. - -Button: Delete -Removes the selected account from the list. - - -Account Details (right side) - -Text: Name -The name of your email provider, e.g.: GMX, Gmail. -This text is only used for displaying the provider, it is not used -for the connection to your email server. - -Text: Server -Name of the POP server of your email provider, e.g.: pop.gmx.net or -imap.googlemail.com. This entry is used to connect to your email provider. - -Text: User -Name of your email user account which is usually identical to your -email address, e.g.: john.doe@gmx.net. - -Text: Password -There must be a password for each user account. Characters are shown as -dots. Passwords are managed by Gnome-Keyring. When you key it in for the -first time or modify an existing password, all changes will be stored to -Keyring. Popper retrieves your passwords when checking for new emails. -Therefore the Keyring has to be unlocked at every start of a user-session -unless the password has been set to BLANK. If want to know more about -keyring you should take a look at the programm "Seahorse" or its -documentation. Seahorse can be found in Ubuntu menu: -system->preferences->passwords and encryption. - -Checkbox: IMAP -You email accounts are either connected via POP or IMAP. In most cases -this can be detected by looking at the server name, e.g.: 'pop.gmx.net'. -If it is 'IMAP' you must switch-on the checkbox, in case of 'POP' you -must uncheck the box. If you are not sure, leave it unchecked. - -Text: Folders -For IMAP accounts you can enter a list of folders that are checked for -new emails. Multiple entries must be separated by comma. If this field -is empty, Popper will always check your 'INBOX' folder. If you enter -folder names, you must enter 'INBOX' explicitly if the inbox should be -checked. -'Gmail' supports labels instead of folders. In contrast to folders, one -email can appear under multiple labels. In this case Popper prevents -duplicated emails in the indicator list. - -Text: Port -If a special port is required to access the email server, you can enter -the port number in this field. Normally you don't have to fill it in. - -Text: Check Frequency (valid for all accounts) -Popper checks your inbox on the server every n minutes for new emails. -This entry determines the time between the checks. Maximum value is -1440 (24 hours), minimum is 1 minute. Some email providers restrict -frequent queries by blocking the request; you should consider this -if you choose a low value. - -Checkbox: Check only once (valid for all accounts) -Usually Popper repeatedly checks the inbox on the email server. If -this option is active, the program will check the inbox only once and -terminates afterwards. Choose this option if you just want to have a -single email check when you start your computer. You avoid that -Popper is running constantly in the background. - - -4.3. Tab 'Indicate' -======================================================================== -Text: Headline -This text is shown as a headline in the indicator menu. - -Text: Headline command -Enter a command to start an email client of your choice, e.g.: -Evolution, Thunderbird, etc. Whenever you click on the headline in -the indicator menu this command will be called. Please understand -that Popper does not communicate with an email client, it only -mirrors the inbox on your email server. If you don't know the correct -command for your email client, just try it in a terminal or look at -the settings in the application menu. -The headline command can also be used for a click on the Desktop -Display (cf. 4.5.). - -Checkbox: Show Sender -Enable this option if you want to see the sender of an email in the -indicator message. - -Selection: John Doe, john.doe@gmx.net -Choose between the natural sender name or the email address. This -is shown in the indicator message. If the email does not contain a -natural name, the address is displayed instead. - -Checkbox: Show Subject -Choose if the email subject is shown in the indicator message. - -Text: Max. subject length -Enter a number that determines at which character position the email's -subject is truncated. If the subject is longer than this length, it -will be indicated by some dots '...' at the end. This setting helps -to control the overall length of the message line. -The max. length is also applied to the subject text in the email list -that is shown in a separate window for summary entries (Summarize by -provider). - -Selection: Subject-Sender, Sender-Subject -Choose the order of the message line in the indicator menu. Select -if you want to see 'subject' first or 'sender' first. - -Checkbox: Show provider in front of message -If you query more than one email account it is helpful to show the -provider name in front of the message. - -Selection: Sort by date, Summarize by provider -Choose if the entries in the notification list shall be sorted by date -or by provider. Sorting by date will put the latest emails on top of the -list (independent of the email account). -The age of an email is shown in a circle at the very right. This may be -seconds (s), minutes (m), hours (h), days (d), weeks (w), months (M) or -years (Y). -If you choose to summarize by provider one entry per provider will be -displayed with the number of new emails next to it. A click on such an -entry will open a list of the emails of that provider in a separate -window. - -Checkbox: Remember last session -If this option is disabled, Popper will notify all emails from the -server's inbox again and again with each restart of the computer. You -can prevent this behaviour by setting this checkbox. In this case -the program will store the status of notified emails wherefore they -are not notified again when you restart. - -Checkbox: Remove entry after click on single email -If this option is enabled, you can remove a single email entry in the -indicator menu by clicking on it. No further action will be done. Therefore -this option only makes sense in combination with a user script. You can -utilize user script 'Click on an email in the indicator menu' to start -a meaningful action. (This feature is experimental.) - -Checkbox: Show only new emails -This option is meant for users who do not clear their inbox on the email -server (either by means of their email-client or if they read emails in -the web-browser and keep read emails in the inbox). Normally Popper -mirrors the inbox and lists all emails in the indicator menu. If this -option is switched on, Popper only shows new emails in the indicator -menu (either as an entry per email or as a counter for each provider). -As soon as you click the headline or the 'clear' function (see 'special -commands') all emails are marked as 'seen' and will not listed again in -the indicator menu. However the summary display (either by function 'list' -or by clicking on e.g. GMX(3)) will show all emails of the inbox(es). -As an example it is possible that clicking on GMX(3) will show seven -emails in the summary window. That means you have 3 new emails but a -total of 7 emails in your GMX inbox. There is no way to mark a single -email in the indicator menu as 'seen'. - -Checkbox: Clear email list after click -Your email client can either delete received emails from the server -or keep it on the server. If you set-up your email client to delete -emails from the server's inbox, you should check this option in order -to clean up the indicator list as soon as you click the headline. The -green envelope (with standard theme) in the panel will also be reset to -'neutral'. If you keep emails on the server you should not check this -option to avoid repetitive filling of the indicator list with emails that -you already know about. - -Menu Entries: -You can have up to three functional entries in your indicator menu. The -will appear on top of your email list. Each menu item has a command that -is executed when you click on the menu entry. Menu entries can also be -achieved in the Desktop Display by right-clicking the mouse on it (cf. 4.5.). - -Checkbox on the very left -Check this box if you want to show the menu entry at all. - -Textfield on the left 'Menu entries' -Contains the name of the menu entry as it will be shown in the -indicator menu. The default settings are: 'Write new email' and -'Open address book'. These names can be adapted according to your -preferences. - -Textfield on the right 'Commands for menu entries' -Contains the corresponding command for that menu entry. The default -settings are: 'evolution mailto:' und 'evolution -c contacts'. -These command are valid for the email-client 'Evolution'; you can adapt -the commands for your prefered email-client, e.g. Thunderbird. Search -in the Internet if you don't know the correspondig commands. - -Special Commands -You can enter some special commands in the text field on the right: -'exit' Terminates Popper -'clear' Clears the list of emails in the indicator menu -'check' Checks for new emails immediately -'list' Show all new emails in a separate window - See also: "Summarize by provider" - - -4.4. Tab 'Notify' -======================================================================== -Checkbox: Notify on new emails -Enabling this option causes a notification bubble for new emails. -The bubble remains about 10 seconds on the screen before it vanishes. -If this checkbox is disables you will not be notified about new -emails except by the envelope in the panel which will turn to green -(with standard theme). - -Textfield: Text for one new email -This text is shown in the notification bubble if you receive -only one new email. Also sender and subject of the email is shown. - -Textfield: Text for multiple new emails -This text is shown in the notification bubble if you receive more -than one new email. - -Checkbox: Play sound on new emails -Enabling this option causes a sound played whenever new emails -arrive. This event comes together with the notification bubble. -The sound file is 'popper.wav' and it is played with 'aplay', which -is preinstalled in Ubuntu. - -Text: Sound file -Enter the name or path of a music file that will be played when new -emails arrive. The program 'aplay' is utilized to play the file. -Supported format is 'wav' but not 'mp3'. -The 'Select' button besides opens a file chooser dialog which opens -the OpenOffice.org sound library as default. - -Button: Play Sound -Press this button to test the selected sound file. If 'Speak notification -text' is enabled, it will also speak that text after the sound file. - -Checkbox: Speak notification text -When you enable this option, Popper will speak the notification text for -one or multiple new emails after the sound file is played. - - -4.5. Tab 'Desktop' -======================================================================== -The Desktop Display is an alternative way of displaying your new emails. -It is a frameless and transparent window that can be positioned and sized -as you like it. New emails are shown with their sender, date and subject -in a subsequent list. The horizontal and vertical limits of the displayed -text depend on the dimensions of the window. You can influence it by setting -the width and height. - -Checkbox: Enable Desktop Display -Switch it on if you want to show the Desktop Display. - -Text: Display Position (x, y) -Enter the absolute position (in pixels) of the display's upper left -corner. (0, 0) is on the very left/top corner of your screen. x is the -horizontal (left to right) and y the vertical (top to bottom) position. -If your settings exceeds the max. dimensions of your screen, you will -not see the Desktop Display. - -Text: Display Size (width, height) -These are the dimensions of the window itself. Width is the horizontal -dimension and height the vertical one. Display Size is also used to -calculate the end of text lines and the end of the email list. -A truncated text line or an incomplete email list is indicated by '...' - -Background Color and Transparency -Clicking on Background Color will open a color selection dialog. A -transparency value of 0% means complete opaqueness whereas 100% means -complete transparency of the Desktop Display. The best value depends on -the color of your desktop wallpaper; just try it. -CAUTION: On complete transparency it may happen that you accidentally -click on the invisible range of the Desktop Display which will cause -the configured behaviour ('close', launching the headline command) with -such a click (see below). - -Textcolor and Font -This lets you select the color of text on the Desktop Display and its -font type and size. The best text color also depends on the level of -transparency and the color of your desktop wallpaper. - -Checkboxes: close and launch headline command -These checkboxes control what happens when you click on the Desktop -Display. 'Close' lets the window disappear from the desktop but does not -delete email entries from the Indicator menu. 'Launch headline command' -will start the command that you entered in the field 'Headline command' -on the tab 'Indicate'. It also clears the Indicator menu entries and -resets the indicator envelope in the panel. This can be used to start your -email client. - -Button: Preview (on/off) -This button shows or closes the Desktop Display to let you check your -settings. The 'close' and/or 'launch headline command' features are not -available in preview mode. The preview display shows some example text -but no real emails. - -The menu entries, which can be configured for the indicator menu (cf. 4.3.), -can also be shown and launched in the Desktop Display by right-clicking -the mouse on it. - - -4.6. Tab 'Script' -======================================================================== -You can configure your own shell scripts or commands that are executed -on the occurance of an event in Popper. Currently two different events -are supported: -- Reception of new emails -- Reception of no new emails -- Click on an email in the indicator menu -- click on a summary entry in the indicator menu - -Tic the checkbox on the left to allow Popper to launch your scripts when -the specific event happens. It is mandatory to have an entry in the -'Script File' text field when the checkbox is switched on. The text field -may contain a command or the path and filename of your shell script. The -button on the right opens a file chooser that points per default to: -/home/user/.popper. You are free to choose any other directory -of your choice, but keept in mind that the shell script must be executable -(you can set this with the file access rights in your file manager). - -When a script for the event 'Click on email' occurs, three arguments will -be passed to script: 'sender, datetime, subject'. - -When a script for the event 'Click on summary entry' occurs, two arguments -will be passed to script: 'account name, number of emails'. - - -4.7. Tab 'Filter' -======================================================================== -The filter allows you to prevent unwanted emails from displaying in -Popper. The checkbox 'apply filter' switches the filter function on/off. -You can enter filter words in the text field 'filter text'. Such words -must be separated by comma. Spaces and line breaks are allowed. Upper -and lower case do not matter. If the filter feature is switched on, -Popper will compare sender and subject text of each incoming email with -the words in your filter text. If any of the words occur in the subject -text, the email will not be displayed by Popper. -ATTENTION: the filter function has no influence on your email programs -like Evolution or Thunderbird. - - -4.8. Tab 'Test' -======================================================================== -The button 'Test Email Connection' will check the connectivity to -your emails provider(s). If you have more than one email account -they will be checked one after another. The text-box underneath the -bottom shows the test results. That helps to test if your settings -are correct. You should not start Popper itself without succeeding -this test. - -If you receive any error messages you should check: -- typos in the fields: Server, User, Password -- do you really have a connection to the internet? -- is the connection blocked by your provider because of frequent - queries? - -Repeat this test whenever you change the settings. If this test -fails also Popper will never work correctly. - - -4.9. Tab 'Help' -======================================================================== -Shows this help text. The language depends on the country settings -of your computer. Currently only 'German' and 'English' is -supported. 'English' will be shown for all countries except Germany. - - -4.10. Buttons 'Restore', 'Cancel', 'Save & Exit' -======================================================================== -At the bottom of the window you can find three buttons: -'Save & Exit' will store all settings and closes the application. -Then it will start Popper. If Popper is already running it will be -closed and restarted. Therefore you don't have to restart your computer -to get the changed settings active. -'Restore' takes the last stored values and discards your current -changes. Restoring is useful if you made any mistakes during your -setup. -Pay attention when using the 'Cancel' button. It will exit the program -immediatelly. Nothing will be saved and Popper will not be started -right after you closed the Configurator. - - -5. Indicator menu -======================================================================== -For a standard Ubuntu installation you will find three entries in the -indicator menu: Chat, E-Mail and Messages. These items start the -associated standard program. - - -5.1. Making Changes -======================================================================== -If you do not need one of the entries, because the program is not being -used or because 'E-Mail' was replaced by Popper, you can adapt the menu. - -Open the direcotry /usr/share/indicators/messages/applications/ and -delete the according file. Each entry has a correspind file: -- empathy for Chat -- evolution for E-Mail -- gwibber for Nachrichten - -Each file contains a refer to starter for the application, which is -stored in the diretory /usr/share/applications/ - - -5.2. Evolution-specific entries -======================================================================== -Things change, if evolution is set up, as there are two more entries -after 'E-Mail': -- Write New Message -- Contacts - -This entries do not have their own file in the directory -/usr/share/indicators/messages/applications/ Instead, the application -starter is responsible for the entries. If you want to delete them, -you have to adapt the starter. Therefore open the starter with a -texteditor and remove the following: -- the line 'X-Ayatana-Desktop-Shortcuts=Compose;Contacts' -- the sections [Compose Shortcut Group] and [Contacts Shortcut Group] -Finally save the changes. - - -5.3. Remarks -======================================================================== -It is strongly recommended not to delete a file or change it, directly. -Instead make sure that you have a copy at another location. You can just -move it back later if you want to undo the changes. - -Of course you need root rights to perform any file system operation in -the directories /usr/share/indicators/messages/applications/ and -/usr/share/applications/. - -You might need to restart your system before the changes affect the menu. - - -6. Bugs, Questions, Forum -======================================================================== -Bugs are reported here (english): https://bugs.launchpad.net/popper -Answers are asked here (english): https://answers.launchpad.net/popper -Requirements and discussions happen here (german): -http://forum.ubuntuusers.de/topic/allgemeiner-email-benachrichtiger - - -======================================================================== -End of help diff --git a/popper_list.glade b/popper_list.glade deleted file mode 100644 index c5ecc9f..0000000 --- a/popper_list.glade +++ /dev/null @@ -1,80 +0,0 @@ - - - - - - - - - - - - - - - - - - Popper List - 680 - 480 - popper.png - normal - - - True - 2 - - - True - True - automatic - automatic - in - - - True - True - liststore - True - True - 0 - - - - - 1 - - - - - True - spread - - - Close - True - True - True - - - - False - False - 0 - - - - - False - end - 0 - - - - - - button_close - - - diff --git a/popper_list.py b/popper_list.py deleted file mode 100644 index ac5b883..0000000 --- a/popper_list.py +++ /dev/null @@ -1,122 +0,0 @@ -#!/usr/bin/env python -# -*- coding: utf-8 -*- -# -# popper_list.py -# -# Copyright 2010 Ralf Hersel -# -# This program is free software; you can redistribute it and/or modify -# it under the terms of the GNU General Public License as published by -# the Free Software Foundation; either version 2 of the License, or -# (at your option) any later version. -# -# This program is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU General Public License for more details. -# -# You should have received a copy of the GNU General Public License -# along with this program; if not, write to the Free Software -# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, -# MA 02110-1301, USA. -# -#======================================================================= -# POPPER : A new email indicator and notifier for POP3 accounts -# popper_settings.py is the GUI for configuration settings -# Author : Ralf Hersel, ralf.hersel@gmx.net -# Version: 0.23 -# Date : Nov 18, 2010 -# Licence: GPL -# -# Libraries ============================================================ - -import gtk - - -# Settings ============================================================= - -class Dialog: - def __init__(self, rows): - builder = gtk.Builder() # build GUI from Glade file - builder.add_from_file("popper_list.glade") - builder.connect_signals({ \ - "gtk_main_quit" : self.exit, \ - "on_button_close_clicked" : self.exit}) - - self.window = builder.get_object("dialog_popper_list") - width, hight = self.get_window_size(rows) # calculate window size - self.window.set_default_size(width, hight) # set the window size - - self.treeview = builder.get_object("treeview") # get the widgets - self.liststore = builder.get_object("liststore") - - renderer = gtk.CellRendererText() - column0 = gtk.TreeViewColumn("Provider", renderer, text=0) - column0.set_sort_column_id(0) # make column sortable - self.treeview.append_column(column0) - - column1 = gtk.TreeViewColumn("From", renderer, text=1) - column1.set_sort_column_id(1) - self.treeview.append_column(column1) - - column2 = gtk.TreeViewColumn("Subject", renderer, text=2) - column2.set_sort_column_id(2) - self.treeview.append_column(column2) - - column3 = gtk.TreeViewColumn("Date", renderer, text=3) - column3.set_sort_column_id(3) - self.treeview.append_column(column3) - - for row in rows: self.liststore.append(row) - self.window.show() - - - def get_window_size(self, rows): - max = 0 # default for widest row - fix = 50 # fix part of width (frame, lines, etc) - charlen = 7 # average width of one character - height = 480 # fixed set window height - min_width = 320 # lower limit for window width - max_width = 1024 # upper limit for window width - alist = self.transpose(rows) # transpose list - alist[0].append('Provider ') # add column headings - alist[1].append('From ') - alist[2].append('Subject ') - alist[3].append('Date ') - print alist - colmax = [] # list with the widest string per column - for col in alist: # loop all columns - temp_widest = 0 # reset temporary widest row value - for row in col: # loop all row strings - if len(row) > temp_widest: temp_widest = len(row) # find the widest string in that column - colmax.append(temp_widest) # save the widest string in that column - for row in colmax: max += row # add all widest strings - width = fix + max * charlen # calculate window width - print width, colmax, max - if width < min_width: width = min_width # avoid width underrun - if width > max_width: width = max_width # avoid width overrun - print width, height - return width, height - - - def transpose(self, lists): # transpose list (switch cols with rows) - return map(lambda *row: list(row), *lists) - - - def exit(self, widget): # exit - gtk.main_quit() - - -# Main ================================================================= - -def main(): - dialog = Dialog([['G','R','D','24.08.2010'], \ - ['Gmail','Martina','Heute schon','25.08.2010'], \ - ['Gmail','Martina Gerisch','Igel','25.08.2010'], \ - ['Gmail','M','Heute schon gefrühstückst? fragte der Hase den Igel. Natürlich habe ich schon gegessen.','25.08.2010'], \ - ['G','Mart','He.','1.1.10'], \ - ['G','D','M','26.08.2010']]) # start Dialog - gtk.main() # start main loop - - -if __name__ == "__main__": main()