ESS_GUIESS_GUI_DocsESS_GUI_batch_fittingESS_GUI_bumps_abstractionESS_GUI_iss1116ESS_GUI_iss879ESS_GUI_iss959ESS_GUI_openclESS_GUI_orderingESS_GUI_sync_sascalccostrafo411magnetic_scattrelease-4.1.1release-4.1.2release-4.2.2release_4.0.1ticket-1009ticket-1094-headlessticket-1242-2d-resolutionticket-1243ticket-1249ticket885unittest-saveload
Last change
on this file since cc0da45 was
8abbb12,
checked in by Jae Cho <jhjcho@…>, 13 years ago
|
some updates
|
-
Property mode set to
100644
|
File size:
1.4 KB
|
Line | |
---|
1 | |
---|
2 | #!/usr/bin/env python |
---|
3 | import os |
---|
4 | import sys |
---|
5 | import imp |
---|
6 | import wx |
---|
7 | #import gui_manager |
---|
8 | from sans.guiframe import gui_manager |
---|
9 | from sans.guiframe.gui_manager import _find_local_config |
---|
10 | |
---|
11 | # For py2exe, import config here |
---|
12 | |
---|
13 | |
---|
14 | path = os.getcwd() |
---|
15 | local_config = _find_local_config('local_config', path) |
---|
16 | if local_config is None: |
---|
17 | path, _ = os.path.split(os.getcwd()) |
---|
18 | local_config = _find_local_config('local_config', path) |
---|
19 | if local_config is None: |
---|
20 | raise RuntimeError, "PrView cannot located local_config.py" |
---|
21 | |
---|
22 | |
---|
23 | class PrApp(gui_manager.ViewApp): |
---|
24 | """ |
---|
25 | """ |
---|
26 | |
---|
27 | class PrView(): |
---|
28 | """ |
---|
29 | """ |
---|
30 | def __init__(self): |
---|
31 | """ |
---|
32 | """ |
---|
33 | #from gui_manager import ViewApp |
---|
34 | #self.gui = gui_manager.ViewApp(0) |
---|
35 | self.gui = PrApp(0) |
---|
36 | # Set the application manager for the GUI |
---|
37 | self.gui.set_manager(self) |
---|
38 | |
---|
39 | # Add perspectives to the basic application |
---|
40 | # Additional perspectives can still be loaded |
---|
41 | # dynamically |
---|
42 | import sans.perspectives.pr as module |
---|
43 | self.pr_plug = module.Plugin(standalone=True) |
---|
44 | self.gui.add_perspective(self.pr_plug) |
---|
45 | |
---|
46 | # Build the GUI |
---|
47 | self.gui.build_gui() |
---|
48 | |
---|
49 | |
---|
50 | # Start the main loop |
---|
51 | self.gui.MainLoop() |
---|
52 | |
---|
53 | |
---|
54 | if __name__ == "__main__": |
---|
55 | sansview = PrView() |
---|
Note: See
TracBrowser
for help on using the repository browser.