Changeset 3641881 in sasview for invariantview/perspectives/invariant
- Timestamp:
- Jul 27, 2010 11:24:22 AM (14 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:
- aa5617d
- Parents:
- 9c1f463
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
invariantview/perspectives/invariant/invariant_panel.py
rcb274d9e r3641881 167 167 data_qmin = min (self._data.x) 168 168 data_qmax = max (self._data.x) 169 self.data_name_tcl.SetValue(str(data_name)) 169 if data.name not in self.data_cbbox.GetItems(): 170 self.data_cbbox.Insert(pos=0, clientData=(data, None), 171 item=data.name) 172 else: 173 pos = self.data_cbbox.FindString(data.name) 174 print "pos", pos 175 self.data_cbbox.SetSelection(pos) 170 176 self.data_min_tcl.SetLabel(str(data_qmin)) 171 177 self.data_max_tcl.SetLabel(str(data_qmax)) … … 679 685 current_compute_num = str(current_state['compute_num']) 680 686 except : 681 raise ValueError, "No such state exists in history" 687 raise 688 #raise ValueError, "No such state exists in history" 682 689 683 690 # get the state at pre_compute_num … … 1179 1186 self.hint_msg_sizer = wx.BoxSizer(wx.HORIZONTAL) 1180 1187 self.loaded_data_name_sizer = wx.BoxSizer(wx.HORIZONTAL) 1181 self.data_name_sizer = wx.BoxSizer(wx.HORIZONTAL)1188 1182 1189 self.data_range_sizer = wx.BoxSizer(wx.HORIZONTAL) 1183 1190 #Sizer related to background and scale … … 1225 1232 self.hint_msg_sizer.Add(self.hint_msg_txt) 1226 1233 1227 self.data_txt = wx.StaticText(self, -1,"Loaded Data: ") 1228 self.data_cbbox = wx.ComboBox(self, -1, size=(260,20)) 1234 self.data_txt = wx.StaticText(self, -1,"Data: ") 1235 self.data_cbbox = wx.ComboBox(self, -1, size=(260,20), 1236 style=wx.CB_READONLY) 1229 1237 self.data_cbbox.Disable() 1230 1238 wx.EVT_COMBOBOX(self.data_cbbox ,-1, self.on_select_data) 1231 1232 1233 #Data name [string] 1234 data_name_txt = wx.StaticText(self, -1, 'Data : ') 1235 1236 self.data_name_tcl = OutputTextCtrl(self, -1,size=(260,20), style=0, name='data_name_tcl') 1237 self.data_name_tcl.SetToolTipString("Data's name.") 1239 1238 1240 self.loaded_data_name_sizer.AddMany([(self.data_txt, 0, 1239 1241 wx.LEFT|wx.RIGHT, 10), 1240 1242 (self.data_cbbox, 0, wx.EXPAND)]) 1241 self.data_name_sizer.AddMany([(data_name_txt, 0, wx.LEFT|wx.RIGHT, 10),1242 (self.data_name_tcl, 0, wx.EXPAND|wx.LEFT,35)])1243 1244 1243 #Data range [string] 1245 1244 data_range_txt = wx.StaticText(self, -1, 'Total Q Range (1/A): ') … … 1257 1256 self.data_name_boxsizer.AddMany([(self.hint_msg_sizer, 0 , wx.ALL, 5), 1258 1257 (self.loaded_data_name_sizer, 0 , wx.ALL, 10), 1259 (self.data_name_sizer, 0 , wx.LEFT|wx.RIGHT, 10),1260 1258 (self.data_range_sizer, 0 , wx.ALL, 10)]) 1261 1259
Note: See TracChangeset
for help on using the changeset viewer.