[fa597990] | 1 | """ |
---|
| 2 | Application settings |
---|
| 3 | """ |
---|
| 4 | import time |
---|
| 5 | import os |
---|
| 6 | from sans.guiframe.gui_style import GUIFRAME |
---|
| 7 | # Version of the application |
---|
| 8 | __appname__ = "SansView" |
---|
| 9 | __version__ = '1.9.2dev_AUG' |
---|
| 10 | __download_page__ = 'http://danse.chem.utk.edu' |
---|
| 11 | __update_URL__ = 'http://danse.chem.utk.edu/sansview_version.php' |
---|
| 12 | |
---|
| 13 | |
---|
| 14 | # Debug message flag |
---|
| 15 | __EVT_DEBUG__ = False |
---|
| 16 | |
---|
| 17 | # Flag for automated testing |
---|
| 18 | __TEST__ = False |
---|
| 19 | |
---|
| 20 | # Debug message should be written to a file? |
---|
| 21 | __EVT_DEBUG_2_FILE__ = False |
---|
| 22 | __EVT_DEBUG_FILENAME__ = "debug.log" |
---|
| 23 | |
---|
| 24 | # About box info |
---|
| 25 | _do_aboutbox = True |
---|
| 26 | _do_tutorial = True |
---|
| 27 | _acknowledgement = \ |
---|
| 28 | '''This software was developed by the University of Tennessee as part of the |
---|
| 29 | Distributed Data Analysis of Neutron Scattering Experiments (DANSE) |
---|
| 30 | project funded by the US National Science Foundation. |
---|
| 31 | |
---|
| 32 | ''' |
---|
| 33 | _homepage = "http://danse.chem.utk.edu" |
---|
| 34 | _download = "http://danse.chem.utk.edu/sansview.html" |
---|
| 35 | _authors = [] |
---|
| 36 | _paper = "http://danse.us/trac/sans/newticket" |
---|
| 37 | _license = "mailto:sansdanse@gmail.com" |
---|
| 38 | |
---|
[50282f8] | 39 | |
---|
| 40 | icon_path = "images" |
---|
| 41 | media_path = "media" |
---|
| 42 | test_path = "test" |
---|
[d4c19e5] | 43 | |
---|
| 44 | _nsf_logo = os.path.join(icon_path, "nsf_logo.png") |
---|
| 45 | _danse_logo = os.path.join(icon_path, "danse_logo.png") |
---|
| 46 | _inst_logo = os.path.join(icon_path, "utlogo.gif") |
---|
[fa597990] | 47 | _nsf_url = "http://www.nsf.gov" |
---|
| 48 | _danse_url = "http://www.cacr.caltech.edu/projects/danse/release/index.html" |
---|
| 49 | _inst_url = "http://www.utk.edu" |
---|
[d4c19e5] | 50 | _corner_image = os.path.join(icon_path, "angles_flat.png") |
---|
| 51 | _welcome_image = os.path.join(icon_path, "SVwelcome.png") |
---|
[fa597990] | 52 | _copyright = "(c) 2009, University of Tennessee" |
---|
| 53 | |
---|
[d4c19e5] | 54 | |
---|
[fa597990] | 55 | #edit the list of file state your plugin can read |
---|
| 56 | APPLICATION_WLIST = 'SansView files (*.svs)|*.svs' |
---|
| 57 | APPLICATION_STATE_EXTENSION = '.svs' |
---|
| 58 | GUIFRAME_WIDTH = 1150 |
---|
| 59 | GUIFRAME_HEIGHT = 840 |
---|
| 60 | PLUGIN_STATE_EXTENSIONS = ['.fitv', '.inv', '.prv'] |
---|
| 61 | PLUGINS_WLIST = ['Fitting files (*.fitv)|*.fitv', |
---|
| 62 | 'Invariant files (*.inv)|*.inv', |
---|
| 63 | 'P(r) files (*.prv)|*.prv'] |
---|
| 64 | PLOPANEL_WIDTH = 415 |
---|
| 65 | PLOPANEL_HEIGTH = 370 |
---|
| 66 | DATAPANEL_WIDTH = 235 |
---|
| 67 | DATAPANEL_HEIGHT = 700 |
---|
| 68 | SPLASH_SCREEN_PATH = os.path.join(icon_path,"SVwelcome_mini.png") |
---|
| 69 | TUTORIAL_PATH = os.path.join(media_path,"Tutorial.pdf") |
---|
| 70 | DEFAULT_STYLE = GUIFRAME.MULTIPLE_APPLICATIONS|GUIFRAME.MANAGER_ON\ |
---|
| 71 | |GUIFRAME.CALCULATOR_ON|GUIFRAME.TOOLBAR_ON |
---|
| 72 | SPLASH_SCREEN_WIDTH = 512 |
---|
| 73 | SPLASH_SCREEN_HEIGHT = 366 |
---|
| 74 | SS_MAX_DISPLAY_TIME = 6000 #6 sec |
---|
[8e3dc19] | 75 | WELCOME_PANEL_ON = True |
---|
[fa597990] | 76 | WELCOME_PANEL_SHOW = False |
---|
| 77 | CLEANUP_PLOT = False |
---|
| 78 | # OPEN and SAVE project menu |
---|
| 79 | OPEN_SAVE_PROJECT_MENU = True |
---|
| 80 | #VIEW MENU |
---|
| 81 | VIEW_MENU = True |
---|
| 82 | #EDIT MENU |
---|
| 83 | EDIT_MENU = True |
---|
| 84 | |
---|
| 85 | SetupIconFile_win = os.path.join(icon_path, "ball.ico") |
---|
| 86 | SetupIconFile_mac = os.path.join(icon_path, "ball.icns") |
---|
| 87 | DefaultGroupName = "DANSE" |
---|
| 88 | OutputBaseFilename = "setupSansView" |
---|
[dcbd4e2c] | 89 | |
---|
[fa597990] | 90 | FIXED_PANEL = True |
---|
| 91 | DATALOADER_SHOW = True |
---|
| 92 | CLEANUP_PLOT = False |
---|
| 93 | WELCOME_PANEL_SHOW = False |
---|
| 94 | #Show or hide toolbar at the start up |
---|
| 95 | TOOLBAR_SHOW = True |
---|
| 96 | # set a default perspective |
---|
| 97 | DEFAULT_PERSPECTIVE = 'None' |
---|
| 98 | |
---|
| 99 | def printEVT(message): |
---|
| 100 | if __EVT_DEBUG__: |
---|
| 101 | print "%g: %s" % (time.clock(), message) |
---|
| 102 | |
---|
| 103 | if __EVT_DEBUG_2_FILE__: |
---|
| 104 | out = open(__EVT_DEBUG_FILENAME__, 'a') |
---|
| 105 | out.write("%10g: %s\n" % (time.clock(), message)) |
---|
| 106 | out.close() |
---|
| 107 | |
---|