1 | """ |
---|
2 | Application settings |
---|
3 | """ |
---|
4 | import os |
---|
5 | import time |
---|
6 | from sas.guiframe.gui_style import GUIFRAME |
---|
7 | # Version of the application |
---|
8 | __appname__ = "DummyView" |
---|
9 | __version__ = '0.0.0' |
---|
10 | __build__ = '1' |
---|
11 | __download_page__ = 'https://github.com/SasView/sasview/releases' |
---|
12 | __update_URL__ = ['raw.githubusercontent.com', |
---|
13 | '/SasView/sasview/master/sasview.latestversion'] |
---|
14 | |
---|
15 | |
---|
16 | # Debug message flag |
---|
17 | __EVT_DEBUG__ = True |
---|
18 | |
---|
19 | # Flag for automated testing |
---|
20 | __TEST__ = False |
---|
21 | |
---|
22 | # Debug message should be written to a file? |
---|
23 | __EVT_DEBUG_2_FILE__ = False |
---|
24 | __EVT_DEBUG_FILENAME__ = "debug.log" |
---|
25 | |
---|
26 | # About box info |
---|
27 | _do_aboutbox = True |
---|
28 | _do_acknowledge = True |
---|
29 | _do_tutorial = True |
---|
30 | _acknowledgement_preamble =\ |
---|
31 | '''To ensure the long term support and development of this software please''' +\ |
---|
32 | ''' remember to do the following.''' |
---|
33 | _acknowledgement_preamble_bullet1 =\ |
---|
34 | '''Acknowledge its use in your publications as suggested below''' |
---|
35 | _acknowledgement_preamble_bullet2 =\ |
---|
36 | '''Reference the following website: http://www.sasview.org''' |
---|
37 | _acknowledgement_preamble_bullet3 =\ |
---|
38 | '''Reference the model you used if appropriate (see documentation for refs)''' |
---|
39 | _acknowledgement_preamble_bullet4 =\ |
---|
40 | '''Send us your reference for our records: developers@sasview.org''' |
---|
41 | _acknowledgement_publications = \ |
---|
42 | '''This work benefited from the use of the SasView application, originally |
---|
43 | developed under NSF award DMR-0520547. |
---|
44 | ''' |
---|
45 | _acknowledgement = \ |
---|
46 | '''This work originally developed as part of the DANSE project funded by the NSF |
---|
47 | under grant DMR-0520547, and currently maintained by NIST, UMD, ORNL, ISIS, ESS |
---|
48 | and ILL. |
---|
49 | |
---|
50 | ''' |
---|
51 | _homepage = "http://www.sasview.org" |
---|
52 | _download = "http://sourceforge.net/projects/sasview/files/" |
---|
53 | _authors = [] |
---|
54 | _paper = "http://sourceforge.net/p/sasview/tickets/" |
---|
55 | _license = "mailto:help@sasview.org" |
---|
56 | _nsf_logo = "images/nsf_logo.png" |
---|
57 | _danse_logo = "images/danse_logo.png" |
---|
58 | _inst_logo = "images/utlogo.gif" |
---|
59 | _nist_logo = "images/nist_logo.png" |
---|
60 | _umd_logo = "images/umd_logo.png" |
---|
61 | _sns_logo = "images/sns_logo.png" |
---|
62 | _isis_logo = "images/isis_logo.png" |
---|
63 | _ess_logo = "images/ess_logo.png" |
---|
64 | _ill_logo = "images/ill_logo.png" |
---|
65 | _nist_url = "http://www.nist.gov/" |
---|
66 | _umd_url = "http://www.umd.edu/" |
---|
67 | _sns_url = "http://neutrons.ornl.gov/" |
---|
68 | _nsf_url = "http://www.nsf.gov" |
---|
69 | _danse_url = "http://www.cacr.caltech.edu/projects/danse/release/index.html" |
---|
70 | _inst_url = "http://www.utk.edu" |
---|
71 | _isis_url = "http://www.isis.stfc.ac.uk/" |
---|
72 | _ess_url = "http://ess-scandinavia.eu/" |
---|
73 | _ill_url = "http://www.ill.eu/" |
---|
74 | _corner_image = "images/angles_flat.png" |
---|
75 | _welcome_image = "images/SVwelcome.png" |
---|
76 | _copyright = "(c) 2008, University of Tennessee" |
---|
77 | #edit the lists below of file state your plugin can read |
---|
78 | #for sasview this how you can edit these lists |
---|
79 | #PLUGIN_STATE_EXTENSIONS = ['.prv','.fitv', '.inv'] |
---|
80 | #APPLICATION_STATE_EXTENSION = '.svs' |
---|
81 | #PLUGINS_WLIST = ['P(r) files (*.prv)|*.prv', |
---|
82 | # 'Fitting files (*.fitv)|*.fitv', |
---|
83 | # 'Invariant files (*.inv)|*.inv'] |
---|
84 | #APPLICATION_WLIST = 'SasView files (*.svs)|*.svs' |
---|
85 | APPLICATION_WLIST = '' |
---|
86 | APPLICATION_STATE_EXTENSION = None |
---|
87 | PLUGINS_WLIST = [] |
---|
88 | PLUGIN_STATE_EXTENSIONS = [] |
---|
89 | SPLASH_SCREEN_PATH = "images/danse_logo.png" |
---|
90 | DEFAULT_STYLE = GUIFRAME.SINGLE_APPLICATION |
---|
91 | SPLASH_SCREEN_WIDTH = 500 |
---|
92 | SPLASH_SCREEN_HEIGHT = 300 |
---|
93 | WELCOME_PANEL_ON = False |
---|
94 | TUTORIAL_PATH = None |
---|
95 | SS_MAX_DISPLAY_TIME = 1500 |
---|
96 | PLOPANEL_WIDTH = 350 |
---|
97 | PLOPANEL_HEIGTH = 350 |
---|
98 | GUIFRAME_WIDTH = 1000 |
---|
99 | GUIFRAME_HEIGHT = 800 |
---|
100 | CONTROL_WIDTH = -1 |
---|
101 | CONTROL_HEIGHT = -1 |
---|
102 | SetupIconFile_win = os.path.join("images", "ball.ico") |
---|
103 | SetupIconFile_mac = os.path.join("images", "ball.icns") |
---|
104 | DefaultGroupName = "DANSE" |
---|
105 | OutputBaseFilename = "setupGuiFrame" |
---|
106 | DATAPANEL_WIDTH = 235 |
---|
107 | DATAPANEL_HEIGHT = 700 |
---|
108 | FIXED_PANEL = True |
---|
109 | DATALOADER_SHOW = True |
---|
110 | CLEANUP_PLOT = False |
---|
111 | WELCOME_PANEL_SHOW = False |
---|
112 | #Show or hide toolbar at the start up |
---|
113 | TOOLBAR_SHOW = True |
---|
114 | # set a default perspective |
---|
115 | DEFAULT_PERSPECTIVE = 'None' |
---|
116 | # OPEN and SAVE project menu |
---|
117 | OPEN_SAVE_PROJECT_MENU = True |
---|
118 | CLEANUP_PLOT = False |
---|
119 | # OPEN and SAVE project menu |
---|
120 | OPEN_SAVE_PROJECT_MENU = False |
---|
121 | #VIEW MENU |
---|
122 | VIEW_MENU = False |
---|
123 | #EDIT MENU |
---|
124 | EDIT_MENU = False |
---|
125 | import wx.lib.newevent |
---|
126 | (StatusBarEvent, EVT_STATUS) = wx.lib.newevent.NewEvent() |
---|
127 | |
---|
128 | def printEVT(message): |
---|
129 | """ |
---|
130 | :TODO - need method documentation |
---|
131 | """ |
---|
132 | if __EVT_DEBUG__: |
---|
133 | print "%g: %s" % (time.clock(), message) |
---|
134 | |
---|
135 | if __EVT_DEBUG_2_FILE__: |
---|
136 | out = open(__EVT_DEBUG_FILENAME__, 'a') |
---|
137 | out.write("%10g: %s\n" % (time.clock(), message)) |
---|
138 | out.close() |
---|
139 | |
---|