Changeset f9be147 in sasview
- Timestamp:
- Sep 20, 2018 10:25:53 AM (6 years ago)
- Branches:
- ESS_GUI, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc
- Children:
- 33d5956
- Parents:
- 114c29f
- git-author:
- Ingo Breßler <dev@…> (09/20/18 10:24:59)
- git-committer:
- Ingo Breßler <dev@…> (09/20/18 10:25:53)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/qtgui/Perspectives/Fitting/FittingWidget.py
r114c29f rf9be147 1860 1860 """ 1861 1861 # Show the chart if ready 1862 data_to_show = self.model_data1863 1862 if self.theory_item is None: 1864 1863 self.recalculatePlotData() 1865 else: 1866 self.communicate.plotRequestedSignal.emit([self.theory_item, data_to_show], self.tab_id) 1864 return 1865 if self.model_data: 1866 self._requestPlots(self.model_data.filename, self.theory_item.model()) 1867 1867 1868 1868 def showPlot(self): … … 1874 1874 # Any models for this page 1875 1875 current_index = self.all_data[self.data_index] 1876 fitpage_name = "" if id is None else "M"+str(self.tab_id) 1877 plots = GuiUtils.plotsFromFilename(self.data.filename, current_index.model()) 1876 item = self._requestPlots(self.data.filename, current_index.model()) 1877 if item: 1878 # fit+data has not been shown - show just data 1879 self.communicate.plotRequestedSignal.emit([item, data_to_show], self.tab_id) 1880 1881 def _requestPlots(self, item_name, item_model): 1882 """ 1883 Emits plotRequestedSignal for all plots found in the given model under the provided item name. 1884 """ 1885 fitpage_name = "" if self.tab_id is None else "M"+str(self.tab_id) 1886 plots = GuiUtils.plotsFromFilename(item_name, item_model) 1878 1887 # Has the fitted data been shown? 1879 1888 data_shown = False 1880 #for plot in plots:1889 item = None 1881 1890 for item, plot in plots.items(): 1882 1891 if fitpage_name in plot.name: 1883 1892 data_shown = True 1884 1893 self.communicate.plotRequestedSignal.emit([item, plot], self.tab_id) 1885 if not data_shown: 1886 # fit+data has not been shown - show just data 1887 self.communicate.plotRequestedSignal.emit([item, data_to_show], self.tab_id) 1894 # return the last data item seen, if nothing was plotted; supposed to be just data) 1895 return None if data_shown else item 1888 1896 1889 1897 def onOptionsUpdate(self):
Note: See TracChangeset
for help on using the changeset viewer.