Changeset efe730d in sasview for src/sas/sasview/sasview.py
- Timestamp:
- Jun 25, 2016 2:07:33 AM (8 years ago)
- Branches:
- master, ESS_GUI, ESS_GUI_Docs, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_iss959, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc, magnetic_scatt, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- 899e084
- Parents:
- 9501661
- git-author:
- Paul Kienzle <pkienzle@…> (06/25/16 00:23:59)
- git-committer:
- Paul Kienzle <pkienzle@…> (06/25/16 02:07:33)
- File:
-
- 1 moved
Legend:
- Unmodified
- Added
- Removed
-
src/sas/sasview/sasview.py
r1be5202 refe730d 16 16 import traceback 17 17 18 log_file = os.path.join(os.path.expanduser("~"), 'sasview.log') 18 19 logging.basicConfig(level=logging.INFO, 19 20 format='%(asctime)s %(levelname)s %(message)s', 20 filename= os.path.join(os.path.expanduser("~"),21 'sasview.log'))21 filename=log_file, 22 ) 22 23 logging.captureWarnings(True) 23 24 … … 75 76 logging.error("Wx version: error reading version") 76 77 77 import wxcruft78 from . import wxcruft 78 79 wxcruft.call_later_fix() 79 80 #wxcruft.trace_new_id() 80 81 81 #Always use private .matplotlib setup to avoid conflicts with other 82 82 #uses of matplotlib 83 #Have to check if .sasview exists first 84 sasdir = os.path.join(os.path.expanduser("~"),'.sasview') 85 if not os.path.exists(sasdir): 86 os.mkdir(sasdir) 87 mplconfigdir = os.path.join(os.path.expanduser("~"),'.sasview','.matplotlib') 83 84 import sas.sasgui 85 mplconfigdir = os.path.join(sas.sasgui.get_user_dir(), '.matplotlib') 88 86 if not os.path.exists(mplconfigdir): 89 87 os.mkdir(mplconfigdir) … … 91 89 reload(sys) 92 90 sys.setdefaultencoding("iso-8859-1") 91 92 93 93 from sas.sasgui.guiframe import gui_manager 94 from sas.sasgui.guiframe.gui_style import GUIFRAME 95 from welcome_panel import WelcomePanel 96 # For py2exe, import config here 97 import local_config 94 from .welcome_panel import WelcomePanel 98 95 PLUGIN_MODEL_DIR = 'plugin_models' 99 96 APP_NAME = 'SasView' … … 175 172 if len(sys.argv) > 1: 176 173 ## Run sasview as an interactive python interpreter 177 #if sys.argv[1] == "-i":178 #sys.argv = ["ipython", "--pylab"]179 #from IPython import start_ipython180 #sys.exit(start_ipython())174 if sys.argv[1] == "-i": 175 sys.argv = ["ipython", "--pylab"] 176 from IPython import start_ipython 177 sys.exit(start_ipython()) 181 178 thing_to_run = sys.argv[1] 182 179 sys.argv = sys.argv[1:]
Note: See TracChangeset
for help on using the changeset viewer.