Changeset 9087214 in sasview for src/sas/sasgui/guiframe
- Timestamp:
- Oct 11, 2016 11:09:47 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, costrafo411, magnetic_scatt, release-4.1.1, release-4.1.2, release-4.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- 4581ac9, 7949dcf7
- Parents:
- 392056d (diff), 46dfee9 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent. - Location:
- src/sas/sasgui/guiframe
- Files:
-
- 1 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/sasgui/guiframe/aboutbox.py
re0f28e6 r49e000b 117 117 self.bitmap_button_ill = wx.BitmapButton(self, -1, wx.NullBitmap) 118 118 self.bitmap_button_ansto = wx.BitmapButton(self, -1, wx.NullBitmap) 119 self.bitmap_button_tudelft = wx.BitmapButton(self, -1, wx.NullBitmap) 119 120 120 121 self.static_line_3 = wx.StaticLine(self, -1) … … 135 136 self.Bind(wx.EVT_BUTTON, self.onIllLogo, self.bitmap_button_ill) 136 137 self.Bind(wx.EVT_BUTTON, self.onAnstoLogo, self.bitmap_button_ansto) 138 self.Bind(wx.EVT_BUTTON, self.onTudelftLogo, self.bitmap_button_tudelft) 137 139 # end wxGlade 138 140 # fill in acknowledgements … … 221 223 logo = wx.Bitmap(image) 222 224 self.bitmap_button_ansto.SetBitmapLabel(logo) 225 226 image = file_dir + "/images/tudelft_logo.png" 227 if os.path.isfile(config._tudelft_logo): 228 image = config._tudelft_logo 229 logo = wx.Bitmap(image) 230 self.bitmap_button_tudelft.SetBitmapLabel(logo) 223 231 224 232 # resize dialog window to fit version number nicely … … 251 259 self.bitmap_button_ill.SetSize(self.bitmap_button_ill.GetBestSize()) 252 260 self.bitmap_button_ansto.SetSize(self.bitmap_button_ansto.GetBestSize()) 261 self.bitmap_button_tudelft.SetSize(self.bitmap_button_tudelft.GetBestSize()) 253 262 # end wxGlade 254 263 … … 314 323 sizer_logos.Add(self.bitmap_button_ansto, 0, 315 324 wx.LEFT|wx.ADJUST_MINSIZE, 2) 325 sizer_logos.Add(self.bitmap_button_tudelft, 0, 326 wx.LEFT|wx.ADJUST_MINSIZE, 2) 316 327 317 328 sizer_logos.Add((10, 50), 0, wx.ADJUST_MINSIZE, 0) … … 405 416 event.Skip() 406 417 418 def onTudelftLogo(self, event): 419 """ 420 """ 421 # wxGlade: DialogAbout.<event_handler> 422 launchBrowser(config._tudelft_url) 423 event.Skip() 424 407 425 # end of class DialogAbout 408 426 -
src/sas/sasgui/guiframe/dataFitting.py
r9b6d62d r1fac6c0 17 17 """ 18 18 """ 19 def __init__(self, x=None, y=None, dx=None, dy=None ):19 def __init__(self, x=None, y=None, dx=None, dy=None, lam=None, dlam=None, isSesans=False): 20 20 """ 21 21 """ … … 24 24 if y is None: 25 25 y = [] 26 PlotData1D.__init__(self, x, y, dx, dy) 27 LoadData1D.__init__(self, x, y, dx, dy) 26 self.isSesans = isSesans 27 PlotData1D.__init__(self, x, y, dx, dy, lam, dlam) 28 LoadData1D.__init__(self, x, y, dx, dy, lam, dlam, isSesans) 28 29 self.id = None 29 30 self.list_group_id = [] … … 68 69 # First, check the data compatibility 69 70 dy, dy_other = self._validity_check(other) 70 result = Data1D(x=[], y=[], dx=None, dy=None)71 result = Data1D(x=[], y=[], lam=[], dx=None, dy=None, dlam=None) 71 72 result.clone_without_data(length=len(self.x), clone=self) 72 73 result.copy_from_datainfo(data1d=self) … … 115 116 # First, check the data compatibility 116 117 self._validity_check_union(other) 117 result = Data1D(x=[], y=[], dx=None, dy=None)118 result = Data1D(x=[], y=[], lam=[], dx=None, dy=None, dlam=None) 118 119 tot_length = len(self.x) + len(other.x) 119 120 result = self.clone_without_data(length=tot_length, clone=result) 121 if self.dlam == None or other.dlam is None: 122 result.dlam = None 123 else: 124 result.dlam = numpy.zeros(tot_length) 120 125 if self.dy == None or other.dy is None: 121 126 result.dy = None … … 141 146 result.y = numpy.append(self.y, other.y) 142 147 result.y = result.y[ind] 148 result.lam = numpy.append(self.lam, other.lam) 149 result.lam = result.lam[ind] 150 if result.dlam != None: 151 result.dlam = numpy.append(self.dlam, other.dlam) 152 result.dlam = result.dlam[ind] 143 153 if result.dy != None: 144 154 result.dy = numpy.append(self.dy, other.dy) … … 260 270 # First, check the data compatibility 261 271 self._validity_check_union(other) 262 result = Data1D(x=[], y=[], dx=None, dy=None)272 result = Data1D(x=[], y=[], lam=[], dx=None, dy=None, dlam=[]) 263 273 tot_length = len(self.x)+len(other.x) 264 274 result.clone_without_data(length=tot_length, clone=self) 275 if self.dlam == None or other.dlam is None: 276 result.dlam = None 277 else: 278 result.dlam = numpy.zeros(tot_length) 265 279 if self.dy == None or other.dy is None: 266 280 result.dy = None … … 285 299 result.y = numpy.append(self.y, other.y) 286 300 result.y = result.y[ind] 301 result.lam = numpy.append(self.lam, other.lam) 302 result.lam = result.lam[ind] 287 303 if result.dy != None: 288 304 result.dy = numpy.append(self.dy, other.dy) -
src/sas/sasgui/guiframe/data_manager.py
rd85c194 r1fac6c0 62 62 if issubclass(Data2D, data.__class__): 63 63 new_plot = Data2D(image=None, err_image=None) 64 else: 65 new_plot = Data1D(x=[], y=[], dx=None, dy=None) 64 elif data.meta_data['loader'] == 'SESANS': 65 new_plot = Data1D(x=[], y=[], dx=None, dy=None, lam=None, dlam=None, isSesans=True) 66 else: 67 new_plot = Data1D(x=[], y=[], dx=None, dy=None, lam=None, dlam=None) #SESANS check??? 66 68 67 69 new_plot.copy_from_datainfo(data)
Note: See TracChangeset
for help on using the changeset viewer.