Changeset 03e04a4 in sasview
- Timestamp:
- Aug 6, 2018 9:49:45 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:
- c0de493, ebfe223
- Parents:
- 060413c (diff), 4bddb9ca (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. - Files:
-
- 3 added
- 7 edited
Legend:
- Unmodified
- Added
- Removed
-
installers/sasview_qt5_osx.spec
r46f59ba ra688be1 44 44 # ADDITIONAL DATA ############################################################ 45 45 datas = [('../src/sas/sasview/images', 'images')] 46 47 datas = [('../src/sas/sasview/images/ball.ico', '.')]48 49 46 datas.append(('../src/sas/sasview/media','media')) 50 47 datas.append(('../src/sas/sasview/test','test')) … … 173 170 debug=False, 174 171 upx=UPX, 175 icon=os.path.join("../src/sas/sasview/images","ball.ic o"),172 icon=os.path.join("../src/sas/sasview/images","ball.icns"), 176 173 version="version.txt", 177 174 console=False ) … … 189 186 app = BUNDLE(coll, 190 187 name='sasview.app', 191 icon='../src/sas/sasview/images/ball.ic o',188 icon='../src/sas/sasview/images/ball.icns', 192 189 bundle_identifier=None) 193 190 -
src/sas/qtgui/MainWindow/GuiManager.py
r8e2cd79 r060413c 27 27 from sas.qtgui.MainWindow.AboutBox import AboutBox 28 28 from sas.qtgui.MainWindow.WelcomePanel import WelcomePanel 29 from sas.qtgui.MainWindow.CategoryManager import CategoryManager 29 30 30 31 from sas.qtgui.MainWindow.DataManager import DataManager … … 134 135 self.ackWidget = Acknowledgements() 135 136 self.aboutWidget = AboutBox() 137 self.categoryManagerWidget = CategoryManager(self._parent, manager=self) 136 138 self.welcomePanel = WelcomePanel() 137 139 self.grid_window = None … … 419 421 self._workspace.actionHide_Toolbar.triggered.connect(self.actionHide_Toolbar) 420 422 self._workspace.actionStartup_Settings.triggered.connect(self.actionStartup_Settings) 421 self._workspace.actionCateg ry_Manager.triggered.connect(self.actionCategry_Manager)423 self._workspace.actionCategory_Manager.triggered.connect(self.actionCategory_Manager) 422 424 # Tools 423 425 self._workspace.actionData_Operation.triggered.connect(self.actionData_Operation) … … 611 613 pass 612 614 613 def actionCategry_Manager(self): 614 """ 615 """ 616 print("actionCategry_Manager TRIGGERED") 617 pass 615 def actionCategory_Manager(self): 616 """ 617 """ 618 self.categoryManagerWidget.show() 618 619 619 620 #============ TOOLS ================= -
src/sas/qtgui/MainWindow/MainWindow.py
re4335ae r3d18691 27 27 except Exception as ex: 28 28 import logging 29 logging.error("Application failed with: " +str(ex))30 print("Application failed with: ", ex)29 logging.error("Application failed with: "+str(ex)) 30 print("Application failed with: ", str(ex)) 31 31 32 32 def closeEvent(self, event): -
src/sas/qtgui/MainWindow/UI/MainWindowUI.ui
r2b39fea r3d18691 75 75 <addaction name="actionStartup_Settings"/> 76 76 <addaction name="separator"/> 77 <addaction name="actionCateg ry_Manager"/>77 <addaction name="actionCategory_Manager"/> 78 78 </widget> 79 79 <widget class="QMenu" name="menuTool"> … … 324 324 </property> 325 325 </action> 326 <action name="actionCateg ry_Manager">326 <action name="actionCategory_Manager"> 327 327 <property name="text"> 328 328 <string>Category Manager</string> -
src/sas/qtgui/Perspectives/Fitting/FittingWidget.py
r97df8a9 r060413c 373 373 self.cbCategory.addItem(CATEGORY_DEFAULT) 374 374 self.cbCategory.addItems(category_list) 375 self.cbCategory.addItem(CATEGORY_STRUCTURE) 375 if CATEGORY_STRUCTURE not in category_list: 376 self.cbCategory.addItem(CATEGORY_STRUCTURE) 376 377 self.cbCategory.setCurrentIndex(0) 377 378 … … 523 524 self.communicate.copyFitParamsSignal.connect(self.onParameterCopy) 524 525 self.communicate.pasteFitParamsSignal.connect(self.onParameterPaste) 526 527 # Communicator signal 528 self.communicate.updateModelCategoriesSignal.connect(self.onCategoriesChanged) 525 529 526 530 def modelName(self): … … 1931 1935 # custom kernel load requires full path 1932 1936 name = os.path.join(ModelUtilities.find_plugins_dir(), model_name+".py") 1933 kernel_module = generate.load_kernel_module(name) 1937 try: 1938 kernel_module = generate.load_kernel_module(name) 1939 except ModuleNotFoundError: 1940 # maybe it's a recategorised custom model? 1941 name = os.path.join(ModelUtilities.find_plugins_dir(), model_name+".py") 1942 # If this rises, it's a valid problem. 1943 kernel_module = generate.load_kernel_module(name) 1934 1944 1935 1945 if hasattr(kernel_module, 'parameters'): … … 2248 2258 self.createNewIndex(residuals_plot) 2249 2259 2260 def onCategoriesChanged(self): 2261 """ 2262 Reload the category/model comboboxes 2263 """ 2264 # Store the current combo indices 2265 current_cat = self.cbCategory.currentText() 2266 current_model = self.cbModel.currentText() 2267 2268 # reread the category file and repopulate the combo 2269 self.cbCategory.blockSignals(True) 2270 self.cbCategory.clear() 2271 self.readCategoryInfo() 2272 self.initializeCategoryCombo() 2273 2274 # Scroll back to the original index in Categories 2275 new_index = self.cbCategory.findText(current_cat) 2276 if new_index != -1: 2277 self.cbCategory.setCurrentIndex(new_index) 2278 self.cbCategory.blockSignals(False) 2279 # ...and in the Models 2280 self.cbModel.blockSignals(True) 2281 new_index = self.cbModel.findText(current_model) 2282 if new_index != -1: 2283 self.cbModel.setCurrentIndex(new_index) 2284 self.cbModel.blockSignals(False) 2285 2286 return 2287 2250 2288 def calcException(self, etype, value, tb): 2251 2289 """ -
src/sas/qtgui/Utilities/GuiUtils.py
r8e2cd79 r3d18691 260 260 # Fitting parameter paste from clipboard 261 261 pasteFitParamsSignal = QtCore.pyqtSignal() 262 # Notify about new categories/models from category manager 263 updateModelCategoriesSignal = QtCore.pyqtSignal() 262 264 263 265 def updateModelItemWithPlot(item, update_data, name=""): -
src/sas/qtgui/Utilities/PluginDefinition.py
rc5e0d84 r060413c 30 30 self.pd_parameter_dict = {} 31 31 32 # Initialize widgets 33 self.addWidgets() 34 35 # Wait for all widgets to finish processing 36 QtWidgets.QApplication.processEvents() 37 32 38 # Initialize signals 33 39 self.addSignals() 34 35 # Initialize widgets36 self.addWidgets()37 40 38 41 def addTooltip(self): … … 160 163 # keep in mind that this is called every time the text changes. 161 164 # mind the performance! 162 self.addTooltip() 163 self.model['text'] = self.txtFunction.toPlainText().lstrip().rstrip() 164 self.modelModified.emit() 165 #self.addTooltip() 166 new_text = self.txtFunction.toPlainText().lstrip().rstrip() 167 if new_text != self.model['text']: 168 self.model['text'] = new_text 169 self.modelModified.emit() 165 170 166 171 def onOverwrite(self):
Note: See TracChangeset
for help on using the changeset viewer.