Changeset 056b569 in sasview for fittingview
- Timestamp:
- Nov 28, 2011 1:48:38 PM (13 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, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, release_4.0.1, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- a1968c4
- Parents:
- fb58234
- Location:
- fittingview/src/sans/perspectives/fitting
- Files:
-
- 1 added
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
fittingview/src/sans/perspectives/fitting/fitting.py
rfa02d95 r056b569 14 14 import re 15 15 import sys 16 import os 16 17 import wx 17 18 import logging … … 216 217 chain_menu.Check(not self.batch_reset_flag) 217 218 chain_menu.Enable(self.batch_on) 219 220 self.menu1.AppendSeparator() 221 self.id_editmodel = wx.NewId() 222 editmodel_help = "Edit cusomized model sample file" 223 self.menu1.Append(self.id_editmodel, "Edit Custom Model", 224 editmodel_help) 225 wx.EVT_MENU(owner, self.id_editmodel, self.edit_custom_model) 226 218 227 #create menubar items 219 228 return [(self.menu1, self.sub_menu)] 220 221 229 230 def edit_custom_model(self, event): 231 """ 232 Get the python editor panel 233 """ 234 from editmodel import PyConsole 235 filename = os.path.join("plugins", "testmodel.py") 236 frame = PyConsole(parent=self.parent, filename=filename) 237 self.put_icon(frame) 238 frame.Show(True) 239 240 def put_icon(self, frame): 241 """ 242 Put icon in the frame title bar 243 """ 244 if hasattr(frame, "IsIconized"): 245 if not frame.IsIconized(): 246 try: 247 icon = self.parent.GetIcon() 248 frame.SetIcon(icon) 249 except: 250 pass 251 222 252 def on_add_sim_page(self, event): 223 253 """
Note: See TracChangeset
for help on using the changeset viewer.