/[thuban]/branches/WIP-pyshapelib-bramz/Thuban/UI/main.py
ViewVC logotype

Annotation of /branches/WIP-pyshapelib-bramz/Thuban/UI/main.py

Parent Directory Parent Directory | Revision Log Revision Log


Revision 19 - (hide annotations)
Tue Sep 4 15:11:27 2001 UTC (23 years, 6 months ago) by bh
Original Path: trunk/thuban/Thuban/UI/main.py
File MIME type: text/x-python
File size: 1216 byte(s)
* MANIFEST.in: Add extensions/pyprojection/LICENSE

* setup.py (thuban_bdist_rpm): New class implementing a Thuban
specific bdist_rpm command.

* Thuban/UI/main.py: Catch ImportError exceptions when importing
the locale module because it may not be available on some
installations.

* extensions/pyprojection/LICENSE: Copy of the license text in
Projection.i. Having it in a separate file makes it easier to
refer to license text in e.g. RPMs

* setup.py: use wx-config instead of wxgtk-config because it's
more generic

* setup.py (ThubanInstall.get_outputs): Add the symlink in
<prefix>/bin to the outputs
(ThubanInstall.link_file): New method to link files. We need this
because the standard copy_files refuses to link non-existing
files.
(ThubanInstall.run): Remove the leading install root from the
script filename if an install root was specified and use the new
link_file method

1 bh 6 #! /usr/bin/python
2     # Copyright (C) 2001 by Intevation GmbH
3     # Authors:
4     # Jan-Oliver Wagner <[email protected]>
5     # Bernhard Herzog <[email protected]>
6     #
7     # This program is free software under the GPL (>=v2)
8     # Read the file COPYING coming with Thuban for details.
9    
10     """
11     The main entry point for the Thuban GUI.
12     """
13    
14     __version__ = "$Revision$"
15    
16     import sys
17    
18     # import wxPython.wx here to get the side effects of the wxPython
19     # import, especially setting the locale to the user's defaults throught
20     # GTK. We then set the locale again to the user's defaults, but this
21     # time we're going through the standard python locale module, so all the
22     # magic necessary to make python work properly is done. Without this,
23     # something harmless like float("1.2") may fail when run under a non-C
24     # locale like de_DE
25     import wxPython.wx
26 bh 19 try:
27     import locale
28     locale.setlocale(locale.LC_ALL, "")
29     except ImportError:
30     # the locale module may not be available on some systems
31     pass
32 bh 6
33     from application import ThubanApplication
34    
35     def main():
36     """Instantiate the application object and run the application"""
37     global app
38     app = ThubanApplication(0)
39     if len(sys.argv) > 1:
40     app.OpenSession(sys.argv[1])
41     app.MainLoop()

Properties

Name Value
svn:eol-style native
svn:keywords Author Date Id Revision

[email protected]
ViewVC Help
Powered by ViewVC 1.1.26