Changeset 2d9526d in sasview for src/sas/sasgui/plottools/plottables.py
- Timestamp:
- Aug 30, 2017 3:55:36 AM (7 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.2.2, ticket-1009, ticket-1094-headless, ticket-1242-2d-resolution, ticket-1243, ticket-1249, ticket885, unittest-saveload
- Children:
- 7b15990, 729198e
- Parents:
- 0f9ea1c
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/sasgui/plottools/plottables.py
r13991957 r2d9526d 239 239 def replace(self, plottable): 240 240 """Replace an existing plottable from the graph""" 241 selected_color = None 241 # If the user has set a custom color, ensure the new plot is the same color 242 selected_color = plottable.custom_color 242 243 selected_plottable = None 243 244 for p in self.plottables.keys(): 244 245 if plottable.id == p.id: 245 246 selected_plottable = p 246 selected_color = self.plottables[p] 247 if selected_color is None: 248 selected_color = self.plottables[p] 247 249 break 248 250 if selected_plottable is not None and selected_color is not None:
Note: See TracChangeset
for help on using the changeset viewer.