Changeset ab8f936 in sasview for guiframe/local_perspectives/plotting/Plotter1D.py
- Timestamp:
- Dec 18, 2008 12:07:37 PM (15 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:
- ef0c170
- Parents:
- 6bcdad1
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
guiframe/local_perspectives/plotting/Plotter1D.py
r1bf33c1 rab8f936 104 104 105 105 is_new = True 106 #print "model panel name",event.plot.name107 106 if event.plot.name in self.plots.keys(): 108 107 # Check whether the class of plottable changed 109 #print "model panel",event.plot.name,event.plot.__class__110 108 if not event.plot.__class__==self.plots[event.plot.name].__class__: 109 #overwrite a plottable using the same name 111 110 self.graph.delete(self.plots[event.plot.name]) 112 111 else: 112 # plottable is already draw on the panel 113 113 is_new = False 114 114 115 115 116 if is_new: 117 # a new plottable overwrites a plotted one using the same id 118 for plottable in self.plots.itervalues(): 119 if event.plot.id==plottable.id : 120 self.graph.delete(plottable) 121 116 122 self.plots[event.plot.name] = event.plot 117 123 self.graph.add(self.plots[event.plot.name]) 118 124 else: 125 #replot the graph 119 126 self.plots[event.plot.name].x = event.plot.x 120 127 self.plots[event.plot.name].y = event.plot.y
Note: See TracChangeset
for help on using the changeset viewer.