display error messages correctly
svn: r21014
This commit is contained in:
parent
642f837658
commit
7dd022bddf
@ -181,10 +181,10 @@ class ErrorDialog(Gtk.MessageDialog):
|
||||
flags=Gtk.DialogFlags.MODAL,
|
||||
type=Gtk.MessageType.ERROR,
|
||||
buttons=Gtk.ButtonsType.CLOSE)
|
||||
self.set_markup('<span weight="bold" size="larger">%s</span>' % msg1)
|
||||
self.set_markup('<span weight="bold" size="larger">%s</span>' % str(msg1))
|
||||
self.format_secondary_text(msg2)
|
||||
self.set_icon(ICON)
|
||||
self.set_title("%s - Gramps" % msg1)
|
||||
self.set_title("%s - Gramps" % str(msg1))
|
||||
self.show()
|
||||
self.run()
|
||||
self.destroy()
|
||||
|
@ -287,12 +287,14 @@ def __startgramps(errors, argparser):
|
||||
from .dialog import ErrorDialog
|
||||
#handle first existing errors in GUI fashion
|
||||
if errors:
|
||||
ErrorDialog(errors[0], errors[1])
|
||||
for error in errors:
|
||||
ErrorDialog(error[0], error[1])
|
||||
Gtk.main_quit()
|
||||
sys.exit(1)
|
||||
|
||||
if argparser.errors:
|
||||
ErrorDialog(argparser.errors[0], argparser.errors[1])
|
||||
for error in argparser.errors:
|
||||
ErrorDialog(argparser.error[0], argparser.error[1])
|
||||
Gtk.main_quit()
|
||||
sys.exit(1)
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user