Changeset 00daba9 in sasview for fittingview/src/sans
- Timestamp:
- Sep 21, 2011 10:15:17 AM (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:
- 6721b75
- Parents:
- 6774d79
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
fittingview/src/sans/perspectives/fitting/simfitpage.py
r1b14795 r00daba9 50 50 Simultaneous page display 51 51 """ 52 self.SetupScrolling() 52 53 ##Font size 53 54 self.SetWindowVariant(variant = FONT_VARIANT) … … 138 139 ## validity of the constraint expression is own by fit engine 139 140 if self.show_constraint.GetValue(): 140 self._set_constraint() 141 if not self._set_constraint(): 142 return 141 143 ## model was actually selected from this page to be fit 142 144 if len(self.model_toFit) >= 1 : … … 405 407 self.ctl2.SetValue(str(model_right + "." + str(param))) 406 408 has_param = True 407 if num_cbox == len(param_list):409 if num_cbox == (len(param_list) + 1): 408 410 break 409 411 self._show_constraint() … … 429 431 nb_fit_param = 0 430 432 for id, model in self.constraint_dict.iteritems(): 431 nb_fit_param += len(self.page_finder[id].get_param2fit()) #len(get_fittableParam(model))433 nb_fit_param += len(self.page_finder[id].get_param2fit()) 432 434 ##Don't add anymore 433 435 if len(self.constraints_list) == nb_fit_param: … … 437 439 self.sizer_constraints.Layout() 438 440 self.sizer2.Layout() 439 self.SetScrollbars(20,20,25,65)441 #self.SetScrollbars(20,20,25,65) 440 442 return 441 443 if len(self.model_toFit) < 2 : … … 444 446 self.sizer_constraints.Layout() 445 447 self.sizer2.Layout() 446 self.SetScrollbars(20,20,25,65)448 #self.SetScrollbars(20,20,25,65) 447 449 return 448 450 … … 488 490 self.sizer_constraints.Layout() 489 491 self.sizer2.Layout() 490 self.SetScrollbars(20,20,25,65)492 #self.SetScrollbars(20,20,25,65) 491 493 492 494 def _hide_constraint(self): … … 692 694 StatusEvent(status= msg )) 693 695 constraint = None 696 if str(param) in self.page_finder[id].get_param2fit(): 697 msg = " Checking constraint for parameter: %s ", param 698 wx.PostEvent(self.parent.parent, 699 StatusEvent(info="info", status= msg )) 700 else: 701 model_name = item[0].GetLabel() 702 fitpage = self.page_finder[id].get_fit_tab_caption() 703 msg = "All constrainted parameters must be set " 704 msg += " adjustable: '%s.%s' "% (model_name, param) 705 msg += "is NOT checked in '%s'. "% fitpage 706 msg += " Please check it to fit or" 707 msg += " remove the line of the constraint." 708 wx.PostEvent(self.parent.parent, 709 StatusEvent(info="error", status= msg )) 710 return False 711 694 712 for fid in self.page_finder[id].iterkeys(): 695 713 self.page_finder[id].set_model_param(param, 696 714 constraint, fid=fid) 697 715 break 716 return True 698 717 699 718 def _fill_sizer_model_list(self,sizer):
Note: See TracChangeset
for help on using the changeset viewer.