Changeset 9ce69ec in sasview for src/sas/qtgui/Perspectives
- Timestamp:
- Sep 18, 2018 3:51:44 AM (6 years ago)
- Branches:
- ESS_GUI, ESS_GUI_batch_fitting, ESS_GUI_bumps_abstraction, ESS_GUI_iss1116, ESS_GUI_iss879, ESS_GUI_opencl, ESS_GUI_ordering, ESS_GUI_sync_sascalc
- Children:
- fc5d2d7f
- Parents:
- 1738173
- git-author:
- Piotr Rozyczko <rozyczko@…> (09/18/18 03:42:03)
- git-committer:
- Piotr Rozyczko <rozyczko@…> (09/18/18 03:51:44)
- Location:
- src/sas/qtgui/Perspectives
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
src/sas/qtgui/Perspectives/Fitting/FittingWidget.py
r305114c r9ce69ec 1849 1849 # Show the chart if ready 1850 1850 data_to_show = self.data if self.data_is_loaded else self.model_data 1851 if data_to_show is not None: 1852 self.communicate.plotRequestedSignal.emit([data_to_show], self.tab_id) 1851 # Any models for this page 1852 current_index = self.all_data[self.data_index] 1853 plots = GuiUtils.plotsFromFilename(self.data.filename, current_index.model()) 1854 fitpage_name = "" if id is None else "M"+str(self.tab_id) 1855 # Has the fitted data been shown? 1856 data_shown = False 1857 #for plot in plots: 1858 for item, plot in plots.items(): 1859 if fitpage_name in plot.name: 1860 data_shown = True 1861 self.communicate.plotRequestedSignal.emit([item, plot], self.tab_id) 1862 if not data_shown: 1863 # fit+data has not been shown - show just data 1864 self.communicate.plotRequestedSignal.emit([item, data_to_show], self.tab_id) 1853 1865 1854 1866 def onOptionsUpdate(self): … … 2080 2092 self.kernel_module = self.models[model_name]() 2081 2093 2094 # Change the model name to a monicker 2095 self.kernel_module.name = self.modelName() 2096 2082 2097 # Explicitly add scale and background with default values 2083 2098 temp_undo_state = self.undo_supported … … 2112 2127 # Structure factor is the only selected model; build it and show all its params 2113 2128 self.kernel_module = self.models[structure_factor]() 2129 self.kernel_module.name = self.modelName() 2114 2130 s_params = self.kernel_module._model_info.parameters 2115 2131 s_params_orig = s_params … … 2122 2138 2123 2139 self.kernel_module = MultiplicationModel(p_kernel, s_kernel) 2140 # Modify the name to correspond to shown items 2141 self.kernel_module.name = self.modelName() 2124 2142 all_params = self.kernel_module._model_info.parameters.kernel_parameters 2125 2143 all_param_names = [param.name for param in all_params] … … 2427 2445 # Bring the GUI to normal state 2428 2446 self.enableInteractiveElements() 2429 2447 if return_data is None: 2448 self.calculateDataFailed("Results not available.") 2449 return 2430 2450 fitted_data = self.logic.new1DPlot(return_data, self.tab_id) 2431 2451 residuals = self.calculateResiduals(fitted_data) -
src/sas/qtgui/Perspectives/Invariant/InvariantPerspective.py
raed0532 r9ce69ec 233 233 234 234 plot_data = GuiUtils.plotsFromCheckedItems(self._manager.filesWidget.model) 235 #self.communicate.plotRequestedSignal.emit([item, plot], self.tab_id) 235 236 236 237 self._manager.filesWidget.plotData(plot_data) … … 347 348 extrapolated_data.name = title 348 349 extrapolated_data.title = title 350 extrapolated_data.style = "Line" 351 extrapolated_data.has_errors = False 352 extrapolated_data.plot_role = Data1D.ROLE_DEFAULT 349 353 350 354 # copy labels and units of axes for plotting … … 378 382 high_out_data.name = title 379 383 high_out_data.title = title 384 high_out_data.style = "Line" 385 high_out_data.has_errors = False 386 high_out_data.plot_role = Data1D.ROLE_DEFAULT 380 387 381 388 # copy labels and units of axes for plotting -
src/sas/qtgui/Perspectives/Inversion/InversionPerspective.py
r855e7ad r9ce69ec 547 547 self.prPlot.plot_role = Data1D.ROLE_RESIDUAL 548 548 GuiUtils.updateModelItemWithPlot(self._data, self.prPlot, title) 549 self.communicate.plotRequestedSignal.emit([self._data,self.prPlot], None) 549 550 if self.dataPlot is not None: 550 551 title = self.dataPlot.name 551 552 self.dataPlot.plot_role = Data1D.ROLE_DEFAULT 553 self.dataPlot.symbol = "Line" 554 self.dataPlot.show_errors = False 552 555 GuiUtils.updateModelItemWithPlot(self._data, self.dataPlot, title) 553 if self.dataPlot is not None or self.prPlot is not None: 554 self.communicate.plotRequestedSignal.emit([self.logic.data], None) 556 self.communicate.plotRequestedSignal.emit([self._data,self.dataPlot], None) 555 557 self.enableButtons() 556 558
Note: See TracChangeset
for help on using the changeset viewer.