gramps/src/gramps.py

64 lines
1.4 KiB
Python
Raw Normal View History

2002-10-20 19:55:16 +05:30
#! /usr/bin/python -O
#-------------------------------------------------------------------------
#
# Load internationalization setup
#
#-------------------------------------------------------------------------
import os
import locale
import gtk.glade
import intl
2002-10-20 19:55:16 +05:30
if os.environ.has_key("GRAMPSI18N"):
loc = os.environ["GRAMPSI18N"]
else:
loc = "locale"
2002-10-20 19:55:16 +05:30
intl.bindtextdomain("gramps",loc)
intl.bind_textdomain_codeset("gramps",'UTF-8')
intl.textdomain("gramps")
2002-10-20 19:55:16 +05:30
locale.setlocale(locale.LC_NUMERIC,"C")
#-------------------------------------------------------------------------
#
# Standard python modules
#
#-------------------------------------------------------------------------
import sys
#-------------------------------------------------------------------------
#
# GNOME/GTK libraries
#
#-------------------------------------------------------------------------
import gtk
import gnome.ui
#-------------------------------------------------------------------------
#
# gramps libraries
#
#-------------------------------------------------------------------------
import gramps_main
if len(sys.argv) > 1:
arg = sys.argv[1]
else:
arg = None
try:
import StartupDialog
if StartupDialog.need_to_run():
StartupDialog.StartupDialog(gramps_main.Gramps,arg)
else:
gramps_main.Gramps(arg)
except:
import DisplayTrace
DisplayTrace.DisplayTrace()
gtk.mainloop()