File: run.py

package info (click to toggle)
enthought-traits-ui 2.0.5-1
  • links: PTS, VCS
  • area: main
  • in suites: lenny
  • size: 15,204 kB
  • ctags: 9,623
  • sloc: python: 45,547; sh: 32; makefile: 19
file content (46 lines) | stat: -rw-r--r-- 1,393 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
#-------------------------------------------------------------------------------
#  
#  Starts the Envisage environment.
#  
#-------------------------------------------------------------------------------

#-------------------------------------------------------------------------------
#  Imports:
#-------------------------------------------------------------------------------

import sys

from enthought.envisage \
    import Application

from plugin_definitions \
    import INCLUDE, PLUGIN_DEFINITIONS

from enthought.developer.helper.fbi \
    import enable_fbi
    
#-------------------------------------------------------------------------------
#  Application entry point:
#-------------------------------------------------------------------------------

if __name__ == '__main__':
    
    # Allow the FBI to handle any exceptions that occur:
    enable_fbi()
    
    # Create an Envisage application:
    application = Application(
        argv               = sys.argv,
        id                 = 'Enthought Developer Tools',
        include            = INCLUDE,
        plugin_definitions = PLUGIN_DEFINITIONS,
        requires_gui       = True
    )

    # Start the application (this call does not return until the GUI event
    # loop terminates):
    application.start()

    # Stop the application:
    application.stop()