# sas.qtgui.Utilities package

## Subpackages

- sas.qtgui.Utilities.About package
  - Subpackages
    - sas.qtgui.Utilities.About.images package
      - Module contents
  - Submodules
  - sas.qtgui.Utilities.About.About module
    - `About`
      - `About.name_image_link`
      - `About.setText()`
      - `About.staticMetaObject`
  - Module contents
- sas.qtgui.Utilities.CustomGUI package
  - Submodules
  - sas.qtgui.Utilities.CustomGUI.CodeEditor module
    - `QCodeEditor`
      - `QCodeEditor.highlightCurrentLine()`
      - `QCodeEditor.lineNumberAreaPaintEvent()`
      - `QCodeEditor.lineNumberAreaWidth()`
      - `QCodeEditor.resizeEvent()`
      - `QCodeEditor.staticMetaObject`
      - `QCodeEditor.updateLineNumberArea()`
      - `QCodeEditor.updateLineNumberAreaWidth()`
    - `QLineNumberArea`
      - `QLineNumberArea.paintEvent()`
      - `QLineNumberArea.sizeHint()`
      - `QLineNumberArea.staticMetaObject`
  - sas.qtgui.Utilities.CustomGUI.ParameterTree module
    - `QParameterTreeWidget`
      - `QParameterTreeWidget.paintEvent()`
      - `QParameterTreeWidget.setDisabledText()`
      - `QParameterTreeWidget.staticMetaObject`
  - Module contents
- sas.qtgui.Utilities.ModelEditors package
  - Subpackages
    - sas.qtgui.Utilities.ModelEditors.AddMultEditor package
      - Subpackages
        - sas.qtgui.Utilities.ModelEditors.AddMultEditor.UI package
          - Submodules
          - sas.qtgui.Utilities.ModelEditors.AddMultEditor.UI.AddMultEditorUI module
            - `Ui_AddMultEditorUI`
              - `Ui_AddMultEditorUI.retranslateUi()`
              - `Ui_AddMultEditorUI.setupUi()`
          - Module contents
      - Submodules
      - sas.qtgui.Utilities.ModelEditors.AddMultEditor.AddMultEditor module
        - `AddMultEditor`
          - `AddMultEditor.onApply()`
          - `AddMultEditor.onHelp()`
          - `AddMultEditor.onNameCheck()`
          - `AddMultEditor.onOperatorChange()`
          - `AddMultEditor.onOverwrite()`
          - `AddMultEditor.readModels()`
          - `AddMultEditor.setupModels()`
          - `AddMultEditor.setupSignals()`
          - `AddMultEditor.staticMetaObject`
          - `AddMultEditor.updateModels()`
          - `AddMultEditor.write_new_model_to_file()`
      - Module contents
    - sas.qtgui.Utilities.ModelEditors.Dialogs package
      - Subpackages
        - sas.qtgui.Utilities.ModelEditors.Dialogs.UI package
          - Submodules
          - sas.qtgui.Utilities.ModelEditors.Dialogs.UI.ModelSelectorUI module
            - `Ui_ModelSelector`
              - `Ui_ModelSelector.retranslateUi()`
              - `Ui_ModelSelector.setupUi()`
          - sas.qtgui.Utilities.ModelEditors.Dialogs.UI.ParameterEditDialogUI module
            - `Ui_ParameterEditDialog`
              - `Ui_ParameterEditDialog.retranslateUi()`
              - `Ui_ParameterEditDialog.setupUi()`
          - Module contents
      - Submodules
      - sas.qtgui.Utilities.ModelEditors.Dialogs.ModelSelector module
        - `ModelSelector`
          - `ModelSelector.addSignals()`
          - `ModelSelector.customModels()`
          - `ModelSelector.getParameters()`
          - `ModelSelector.onClose()`
          - `ModelSelector.onLoad()`
          - `ModelSelector.onLoadModel()`
          - `ModelSelector.onSelectionChanged()`
          - `ModelSelector.populateModelTree()`
          - `ModelSelector.readCustomCategoryInfo()`
          - `ModelSelector.regenerateModelDict()`
          - `ModelSelector.returnModelParamsSignal`
          - `ModelSelector.setupModelDict()`
          - `ModelSelector.staticMetaObject`
      - sas.qtgui.Utilities.ModelEditors.Dialogs.ParameterEditDialog module
        - `ParameterEditDialog`
          - `ParameterEditDialog.addSignals()`
          - `ParameterEditDialog.adjustTableSize()`
          - `ParameterEditDialog.getValues()`
          - `ParameterEditDialog.getValuesFromTable()`
          - `ParameterEditDialog.onCellPressed()`
          - `ParameterEditDialog.onClose()`
          - `ParameterEditDialog.onLoad()`
          - `ParameterEditDialog.onSave()`
          - `ParameterEditDialog.returnEditedParamSignal`
          - `ParameterEditDialog.returnNewParamsSignal`
          - `ParameterEditDialog.staticMetaObject`
          - `ParameterEditDialog.writeValuesToTable()`
      - Module contents
    - sas.qtgui.Utilities.ModelEditors.ReparamEditor package
      - Subpackages
        - sas.qtgui.Utilities.ModelEditors.ReparamEditor.UI package
          - Submodules
          - sas.qtgui.Utilities.ModelEditors.ReparamEditor.UI.ReparameterizationEditorUI module
            - `Ui_ReparameterizationEditor`
              - `Ui_ReparameterizationEditor.retranslateUi()`
              - `Ui_ReparameterizationEditor.setupUi()`
          - Module contents
      - Submodules
      - sas.qtgui.Utilities.ModelEditors.ReparamEditor.ReparameterizationEditor module
        - `ReparameterizationEditor`
          - `ReparameterizationEditor.addSignals()`
          - `ReparameterizationEditor.addSubItems()`
          - `ReparameterizationEditor.addTooltips()`
          - `ReparameterizationEditor.badPropsCheck()`
          - `ReparameterizationEditor.checkDuplicates()`
          - `ReparameterizationEditor.checkModel()`
          - `ReparameterizationEditor.closeEvent()`
          - `ReparameterizationEditor.editSelected()`
          - `ReparameterizationEditor.editorModelModified()`
          - `ReparameterizationEditor.generateModelText()`
          - `ReparameterizationEditor.getParamProperties()`
          - `ReparameterizationEditor.getParameterSelection()`
          - `ReparameterizationEditor.loadParams()`
          - `ReparameterizationEditor.onAddParam()`
          - `ReparameterizationEditor.onApply()`
          - `ReparameterizationEditor.onDeleteParam()`
          - `ReparameterizationEditor.onHelp()`
          - `ReparameterizationEditor.onLoad()`
          - `ReparameterizationEditor.onModelHelp()`
          - `ReparameterizationEditor.onSelectModel()`
          - `ReparameterizationEditor.parameterWarning()`
          - `ReparameterizationEditor.removeParameterWarning()`
          - `ReparameterizationEditor.setWindowEdited()`
          - `ReparameterizationEditor.staticMetaObject`
          - `ReparameterizationEditor.updateParam()`
          - `ReparameterizationEditor.writeModel()`
      - Module contents
    - sas.qtgui.Utilities.ModelEditors.TabbedEditor package
      - Subpackages
        - sas.qtgui.Utilities.ModelEditors.TabbedEditor.UI package
          - Submodules
          - sas.qtgui.Utilities.ModelEditors.TabbedEditor.UI.ModelEditor module
            - `Ui_ModelEditor`
              - `Ui_ModelEditor.retranslateUi()`
              - `Ui_ModelEditor.setupUi()`
          - sas.qtgui.Utilities.ModelEditors.TabbedEditor.UI.PluginDefinitionUI module
            - `Ui_PluginDefinition`
              - `Ui_PluginDefinition.retranslateUi()`
              - `Ui_PluginDefinition.setupUi()`
          - sas.qtgui.Utilities.ModelEditors.TabbedEditor.UI.TabbedModelEditor module
            - `Ui_TabbedModelEditor`
              - `Ui_TabbedModelEditor.retranslateUi()`
              - `Ui_TabbedModelEditor.setupUi()`
          - Module contents
      - Submodules
      - sas.qtgui.Utilities.ModelEditors.TabbedEditor.ModelEditor module
        - `ModelEditor`
          - `ModelEditor.addSignals()`
          - `ModelEditor.getModel()`
          - `ModelEditor.modelModified`
          - `ModelEditor.onEdit()`
          - `ModelEditor.setupWidgets()`
          - `ModelEditor.staticMetaObject`
      - sas.qtgui.Utilities.ModelEditors.TabbedEditor.PluginDefinition module
        - `PluginDefinition`
          - `PluginDefinition.addSignals()`
          - `PluginDefinition.addTooltips()`
          - `PluginDefinition.addWidgets()`
          - `PluginDefinition.checkPyModelExists()`
          - `PluginDefinition.enablePyCheckboxSignal`
          - `PluginDefinition.getModel()`
          - `PluginDefinition.includePolydisperseFuncsSignal`
          - `PluginDefinition.initializeModel()`
          - `PluginDefinition.modelModified`
          - `PluginDefinition.omitPolydisperseFuncsSignal`
          - `PluginDefinition.onDescriptionChanged()`
          - `PluginDefinition.onFormVolumeFunctionChanged()`
          - `PluginDefinition.onFunctionChanged()`
          - `PluginDefinition.onGenC()`
          - `PluginDefinition.onGenPython()`
          - `PluginDefinition.onOverwrite()`
          - `PluginDefinition.onParamsChanged()`
          - `PluginDefinition.onParamsPDChanged()`
          - `PluginDefinition.onPluginNameChanged()`
          - `PluginDefinition.sendNewDescriptionSignal`
          - `PluginDefinition.sendNewFormVolumeSignal`
          - `PluginDefinition.sendNewIqSignal`
          - `PluginDefinition.sendNewParamSignal`
          - `PluginDefinition.setModelTypeCheckBoxEnabledState()`
          - `PluginDefinition.staticMetaObject`
          - `PluginDefinition.updateParamTableFromEditor()`
        - `remove_empty_table_rows()`
      - sas.qtgui.Utilities.ModelEditors.TabbedEditor.TabbedModelEditor module
        - `TabbedModelEditor`
          - `TabbedModelEditor.FunctionBodyExtractor`
            - `TabbedModelEditor.FunctionBodyExtractor.visit_FunctionDef()`
          - `TabbedModelEditor.addSignals()`
          - `TabbedModelEditor.addTab()`
          - `TabbedModelEditor.addWidgets()`
          - `TabbedModelEditor.allBuiltinModels()`
          - `TabbedModelEditor.applySignal`
          - `TabbedModelEditor.canWriteModel()`
          - `TabbedModelEditor.closeEvent()`
          - `TabbedModelEditor.createOrUpdateTab()`
          - `TabbedModelEditor.editorModelModified()`
          - `TabbedModelEditor.extractFunctionBody()`
          - `TabbedModelEditor.findFirstError()`
          - `TabbedModelEditor.generateCModel()`
          - `TabbedModelEditor.generatePyModel()`
          - `TabbedModelEditor.getModel()`
          - `TabbedModelEditor.getParamHelper()`
          - `TabbedModelEditor.includePolydisperseFuncs()`
          - `TabbedModelEditor.isWidgetInTab()`
          - `TabbedModelEditor.loadFile()`
          - `TabbedModelEditor.noModelCheckWarning()`
          - `TabbedModelEditor.omitPolydisperseFuncs()`
          - `TabbedModelEditor.onApply()`
          - `TabbedModelEditor.onCancel()`
          - `TabbedModelEditor.onHelp()`
          - `TabbedModelEditor.onLoad()`
          - `TabbedModelEditor.onModifiedExit()`
          - `TabbedModelEditor.pluginTitleSet()`
          - `TabbedModelEditor.populateWidgetTextBox()`
          - `TabbedModelEditor.saveClose()`
          - `TabbedModelEditor.saveOverrideWarning()`
          - `TabbedModelEditor.setPluginActive()`
          - `TabbedModelEditor.setTabEdited()`
          - `TabbedModelEditor.staticMetaObject`
          - `TabbedModelEditor.strFromParamDict()`
          - `TabbedModelEditor.updateFromEditor()`
          - `TabbedModelEditor.updateFromPlugin()`
          - `TabbedModelEditor.updateToPlugin()`
          - `TabbedModelEditor.writeFile()`
      - Module contents
  - Module contents
- sas.qtgui.Utilities.MuMag package
  - Subpackages
    - sas.qtgui.Utilities.MuMag.SANSData package
      - Module contents
    - sas.qtgui.Utilities.MuMag.UI package
      - Submodules
      - sas.qtgui.Utilities.MuMag.UI.MuMagUI module
        - `Ui_MuMagTool`
          - `Ui_MuMagTool.retranslateUi()`
          - `Ui_MuMagTool.setupUi()`
      - Module contents
  - Submodules
  - sas.qtgui.Utilities.MuMag.MuMag module
    - `MuMag`
      - `MuMag.get_fit_parameters()`
      - `MuMag.hide_everything()`
      - `MuMag.importData()`
      - `MuMag.onFit()`
      - `MuMag.onHelp()`
      - `MuMag.onSave()`
      - `MuMag.show_fit_results()`
      - `MuMag.show_input_data()`
      - `MuMag.staticMetaObject`
    - `main()`
  - sas.qtgui.Utilities.MuMag.MuMagLib module
    - `MuMagLib`
      - `MuMagLib.directory_popup()`
      - `MuMagLib.import_data()`
      - `MuMagLib.least_squares_parallel()`
      - `MuMagLib.least_squares_perpendicular()`
      - `MuMagLib.logger`
      - `MuMagLib.mu_0`
      - `MuMagLib.nice_log_plot_bounds()`
      - `MuMagLib.refine_exchange_A()`
      - `MuMagLib.save_data()`
      - `MuMagLib.simple_fit()`
      - `MuMagLib.sweep_exchange_A()`
      - `MuMagLib.uncertainty()`
  - sas.qtgui.Utilities.MuMag.datastructures module
    - `ExperimentGeometry`
      - `ExperimentGeometry.PARALLEL`
      - `ExperimentGeometry.PERPENDICULAR`
    - `ExperimentalData`
      - `ExperimentalData.applied_field`
      - `ExperimentalData.demagnetising_field`
      - `ExperimentalData.restrict_by_index()`
      - `ExperimentalData.saturation_magnetisation`
      - `ExperimentalData.scattering_curve`
    - `FitFailure`
    - `FitParameters`
      - `FitParameters.exchange_A_max`
      - `FitParameters.exchange_A_min`
      - `FitParameters.exchange_A_n`
      - `FitParameters.experiment_geometry`
      - `FitParameters.min_applied_field`
      - `FitParameters.q_max`
    - `FitResults`
      - `FitResults.input_data`
      - `FitResults.optimal_exchange_A_uncertainty`
      - `FitResults.parameters`
      - `FitResults.refined_fit_data`
      - `FitResults.sweep_data`
    - `LeastSquaresOutput`
      - `LeastSquaresOutput.I_residual`
      - `LeastSquaresOutput.I_residual_stdev`
      - `LeastSquaresOutput.I_simulated`
      - `LeastSquaresOutput.S_H`
      - `LeastSquaresOutput.S_H_stdev`
      - `LeastSquaresOutput.exchange_A`
      - `LeastSquaresOutput.exchange_A_chi_sq`
      - `LeastSquaresOutput.q`
    - `LeastSquaresOutputParallel`
    - `LeastSquaresOutputPerpendicular`
      - `LeastSquaresOutputPerpendicular.S_M`
      - `LeastSquaresOutputPerpendicular.S_M_stdev`
    - `LoadFailure`
    - `SweepOutput`
      - `SweepOutput.exchange_A_checked`
      - `SweepOutput.exchange_A_chi_sq`
      - `SweepOutput.optimal`
  - sas.qtgui.Utilities.MuMag.models module
    - `LorentzianModelPAR()`
    - `LorentzianModelPERP()`
    - `LorentzianNoisyModelPERP()`
    - `SANS_Model_PAR()`
    - `SANS_Model_PERP()`
  - Module contents
- sas.qtgui.Utilities.NewVersion package
  - Submodules
  - sas.qtgui.Utilities.NewVersion.NewVersionAvailable module
    - `NewVersionAvailable`
      - `NewVersionAvailable.cancel()`
      - `NewVersionAvailable.go()`
      - `NewVersionAvailable.staticMetaObject`
    - `get_current_release_version()`
    - `main()`
    - `maybe_prompt_new_version_download()`
  - Module contents
- sas.qtgui.Utilities.OrientationViewer package
  - Subpackages
    - sas.qtgui.Utilities.OrientationViewer.UI package
      - Submodules
      - sas.qtgui.Utilities.OrientationViewer.UI.OrientationViewerControllerUI module
        - `Ui_OrientationViewierControllerUI`
          - `Ui_OrientationViewierControllerUI.retranslateUi()`
          - `Ui_OrientationViewierControllerUI.setupUi()`
      - Module contents
  - Submodules
  - sas.qtgui.Utilities.OrientationViewer.OrientationViewer module
    - `OrientationViewer`
      - `OrientationViewer.a`
      - `OrientationViewer.arrow_color`
      - `OrientationViewer.arrow_size`
      - `OrientationViewer.b`
      - `OrientationViewer.c`
      - `OrientationViewer.closeEvent()`
      - `OrientationViewer.colormap`
      - `OrientationViewer.create_calculator()`
      - `OrientationViewer.create_ghost()`
      - `OrientationViewer.cube_color`
      - `OrientationViewer.ghost_color`
      - `OrientationViewer.log_I_max`
      - `OrientationViewer.log_I_min`
      - `OrientationViewer.log_I_range`
      - `OrientationViewer.n_ghosts_per_perameter`
      - `OrientationViewer.n_q_samples`
      - `OrientationViewer.onHelp()`
      - `OrientationViewer.on_angle_changed()`
      - `OrientationViewer.on_angle_changing()`
      - `OrientationViewer.orient_ghosts()`
      - `OrientationViewer.polydispersity_distribution`
      - `OrientationViewer.polydispersity_sample_count()`
      - `OrientationViewer.q_max`
      - `OrientationViewer.scattering_data()`
      - `OrientationViewer.screen_scale`
      - `OrientationViewer.staticMetaObject`
    - `main()`
    - `show_orientation_viewer()`
  - sas.qtgui.Utilities.OrientationViewer.OrientationViewerController module
    - `Orientation`
      - `Orientation.dphi`
      - `Orientation.dpsi`
      - `Orientation.dtheta`
      - `Orientation.phi`
      - `Orientation.psi`
      - `Orientation.theta`
    - `OrientationViewierController`
      - `OrientationViewierController.onSliderMoved()`
      - `OrientationViewierController.onSliderSet()`
      - `OrientationViewierController.setLabels()`
      - `OrientationViewierController.sliderMoved`
      - `OrientationViewierController.sliderSet`
      - `OrientationViewierController.staticMetaObject`
    - `main()`
  - Module contents
- sas.qtgui.Utilities.Preferences package
  - Subpackages
    - sas.qtgui.Utilities.Preferences.UI package
      - Submodules
      - sas.qtgui.Utilities.Preferences.UI.PreferencesUI module
        - `Ui_preferencesUI`
          - `Ui_preferencesUI.retranslateUi()`
          - `Ui_preferencesUI.setupUi()`
      - Module contents
  - Submodules
  - sas.qtgui.Utilities.Preferences.DisplayPreferencesWidget module
    - `DisplayPreferencesWidget`
      - `DisplayPreferencesWidget.staticMetaObject`
  - sas.qtgui.Utilities.Preferences.PlottingPreferencesWidget module
    - `PlottingPreferencesWidget`
      - `PlottingPreferencesWidget.staticMetaObject`
  - sas.qtgui.Utilities.Preferences.PreferencesPanel module
    - `PreferencesPanel`
      - `PreferencesPanel.addWidget()`
      - `PreferencesPanel.addWidgets()`
      - `PreferencesPanel.close()`
      - `PreferencesPanel.closeEvent()`
      - `PreferencesPanel.help()`
      - `PreferencesPanel.prefMenuChanged()`
      - `PreferencesPanel.registerPerspectivePreferences()`
      - `PreferencesPanel.restoreDefaultPreferences()`
      - `PreferencesPanel.setMenuByName()`
      - `PreferencesPanel.setWidgetIndex()`
      - `PreferencesPanel.set_invalid_input()`
      - `PreferencesPanel.stageSingleChange()`
      - `PreferencesPanel.staticMetaObject`
      - `PreferencesPanel.unStageSingleChange()`
      - `PreferencesPanel.unset_invalid_input()`
    - `restart_main()`
  - sas.qtgui.Utilities.Preferences.PreferencesWidget module
    - `PrefDoubleValidator`
      - `PrefDoubleValidator.fixup()`
      - `PrefDoubleValidator.staticMetaObject`
      - `PrefDoubleValidator.validate()`
    - `PrefFloatEdit`
      - `PrefFloatEdit.staticMetaObject`
      - `PrefFloatEdit.text()`
    - `PrefIntEdit`
      - `PrefIntEdit.staticMetaObject`
      - `PrefIntEdit.text()`
    - `PreferencesWidget`
      - `PreferencesWidget.addCheckBox()`
      - `PreferencesWidget.addComboBox()`
      - `PreferencesWidget.addFloatInput()`
      - `PreferencesWidget.addHeaderText()`
      - `PreferencesWidget.addHorizontalLine()`
      - `PreferencesWidget.addIntegerInput()`
      - `PreferencesWidget.addTextInput()`
      - `PreferencesWidget.applyNonConfigValues()`
      - `PreferencesWidget.restoreDefaults()`
      - `PreferencesWidget.restoreGUIValuesFromConfig()`
      - `PreferencesWidget.staticMetaObject`
    - `QHLine`
      - `QHLine.staticMetaObject`
    - `cb_replace_all_items_with_new()`
  - Module contents
- sas.qtgui.Utilities.Reports package
  - Subpackages
    - sas.qtgui.Utilities.Reports.UI package
      - Submodules
      - sas.qtgui.Utilities.Reports.UI.ReportDialogUI module
        - `Ui_ReportDialogUI`
          - `Ui_ReportDialogUI.retranslateUi()`
          - `Ui_ReportDialogUI.setupUi()`
      - Module contents
  - Submodules
  - sas.qtgui.Utilities.Reports.ReportDialog module
    - `ReportDialog`
      - `ReportDialog.onPrint()`
      - `ReportDialog.onSave()`
      - `ReportDialog.save_pdf()`
      - `ReportDialog.setupDialog()`
      - `ReportDialog.staticMetaObject`
      - `ReportDialog.write_string()`
  - sas.qtgui.Utilities.Reports.reportdata module
    - `ReportData`
      - `ReportData.html`
      - `ReportData.text`
  - sas.qtgui.Utilities.Reports.reports module
    - `ReportBase`
      - `ReportBase.add_data_details()`
      - `ReportBase.add_image_from_bytes()`
      - `ReportBase.add_image_from_file()`
      - `ReportBase.add_plot()`
      - `ReportBase.add_table()`
      - `ReportBase.add_table_dict()`
      - `ReportBase.html`
      - `ReportBase.report_data`
      - `ReportBase.save_html()`
      - `ReportBase.save_pdf()`
      - `ReportBase.save_text()`
      - `ReportBase.text`
    - `main()`
    - `pretty_units`
      - `pretty_units.tagname`
  - Module contents
- sas.qtgui.Utilities.UI package
  - Submodules
  - sas.qtgui.Utilities.UI.DocViewWidgetUI module
    - `Ui_DocViewerWindow`
      - `Ui_DocViewerWindow.retranslateUi()`
      - `Ui_DocViewerWindow.setupUi()`
  - sas.qtgui.Utilities.UI.FileConverterUI module
    - `Ui_FileConverterUI`
      - `Ui_FileConverterUI.retranslateUi()`
      - `Ui_FileConverterUI.setupUi()`
  - sas.qtgui.Utilities.UI.FrameSelectUI module
    - `Ui_FrameSelect`
      - `Ui_FrameSelect.retranslateUi()`
      - `Ui_FrameSelect.setupUi()`
  - sas.qtgui.Utilities.UI.GridPanelUI module
    - `Ui_GridPanelUI`
      - `Ui_GridPanelUI.retranslateUi()`
      - `Ui_GridPanelUI.setupUi()`
  - sas.qtgui.Utilities.UI.ImageViewerOptionsUI module
    - `Ui_ImageViewerOptionsUI`
      - `Ui_ImageViewerOptionsUI.retranslateUi()`
      - `Ui_ImageViewerOptionsUI.setupUi()`
  - sas.qtgui.Utilities.UI.ImageViewerUI module
    - `Ui_ImageViewerUI`
      - `Ui_ImageViewerUI.retranslateUi()`
      - `Ui_ImageViewerUI.setupUi()`
  - sas.qtgui.Utilities.UI.PluginManagerUI module
    - `Ui_PluginManagerUI`
      - `Ui_PluginManagerUI.retranslateUi()`
      - `Ui_PluginManagerUI.setupUi()`
  - sas.qtgui.Utilities.UI.PreferencesUI module
    - `Ui_preferencesUI`
      - `Ui_preferencesUI.retranslateUi()`
      - `Ui_preferencesUI.setupUi()`
  - Module contents
- sas.qtgui.Utilities.WhatsNew package
  - Subpackages
    - sas.qtgui.Utilities.WhatsNew.css package
      - Module contents
  - Submodules
  - sas.qtgui.Utilities.WhatsNew.WhatsNew module
    - `WhatsNew`
      - `WhatsNew.close_me()`
      - `WhatsNew.has_new_messages()`
      - `WhatsNew.next_file()`
      - `WhatsNew.prev_file()`
      - `WhatsNew.set_enable_disable_prev_next()`
      - `WhatsNew.show_file()`
      - `WhatsNew.staticMetaObject`
    - `WhatsNewBrowser`
      - `WhatsNewBrowser.loadResource()`
      - `WhatsNewBrowser.setHtml()`
      - `WhatsNewBrowser.staticMetaObject`
    - `main()`
    - `whats_new_messages()`
  - sas.qtgui.Utilities.WhatsNew.newer module
    - `newest()`
    - `reduced_version()`
    - `strictly_newer_than()`
  - Module contents

## Submodules

## sas.qtgui.Utilities.CategoryInstaller module

Class for making sure all category stuff is installed and works fine.

Copyright (c) Institut Laue-Langevin 2012

@author kieranrcampbell@gmail.com @modified by NIST/MD sasview team

class sas.qtgui.Utilities.CategoryInstaller.CategoryInstaller

  Bases: `object`

  Class for making sure all category stuff is installed

  Note - class is entirely static!

  static check_install(homedir=None, model_list=None)

    the main method of this class makes sure categories.json exists and if not compile it and install :param homefile: Override the default home directory :param model_list: List of model names except customized models

  static get_default_file()
  static get_user_file()

    returns the user data file, eg .sasview/categories.json.json

## sas.qtgui.Utilities.ConnectionProxy module

class sas.qtgui.Utilities.ConnectionProxy.ConnectionProxy(url, timeout)

  Bases: `object`

  connect()

    Performs the request and gets a response from self.url @return: response object from urllib2.urlopen

## sas.qtgui.Utilities.DocViewWidget module

class sas.qtgui.Utilities.DocViewWidget.DocViewWindow(source: Path)

  Bases: `QDialog`, `Ui_DocViewerWindow`

  Instantiates a window to view documentation using a QWebEngineViewer widget

  closeEvent(event: QCloseEvent)

    Close window Keep as a separate method to allow for additional functionality when closing

  initialLoadHtml()

    Undertake preflight checks and if OK, load the requested page

  initializeSignals()

    Initialize all external signals that will trigger events for the window.

  load404()
  loadHtml()

    Loads the HTML file specified when this python is called from another part of the program.

  onCloseButtonClicked()

    Close window Keep as a separate method to allow for additional functionality when closing

  onDownload(download_item)
  onDownloadFinished(item)
  onShow()

    Show window Keep as a separate method to allow for additional functionality when opening

  processUrl() → QUrl

    Process path into proper QUrl for use in QWebViewer.

    Returns:

      A QtCore.QUrl object built using self.source.

  refresh()
  staticMetaObject = PySide6.QtCore.QMetaObject("DocViewWindow" inherits "QDialog": )
  updateTitle()

    Set the title of the window to include the name of the document, found in the first <h1> tags.

## sas.qtgui.Utilities.FileConverter module

File Converter Widget

class sas.qtgui.Utilities.FileConverter.FileConverterWidget(parent=None)

  Bases: `QDialog`, `Ui_FileConverterUI`

  Class to describe the behaviour of the File Converter widget

  addSlots()

    Create callbacks for UI elements and outside signals

  askFrameRange(n_frames=1)

    Display a dialog asking the user to input the range of frames they would like to export

    Parameters:

      n_frames – How many frames the loaded data file has

    Returns:

      A dictionary containing the parameters input by the user

  convert1Ddata(qdata, iqdata, ofile, metadata)

    Formats a 1D array of q_axis data and a 2D array of I axis data (where each row of iqdata is a separate row), into an array of Data1D objects

  extractBSLdata(filename)

    Extracts data from a 2D BSL file

    Parameters:

      filename – The header file to extract the data from

    Return x_data:

      A 1D array containing all the x coordinates of the data

    Return y_data:

      A 1D array containing all the y coordinates of the data

    Return frame_data:

      A dictionary of the form {frame_number: data}, where data is a 2D numpy array containing the intensity data

  getDetectorMetadata()

    Read the detector metadata fields and put them in the dictionary

  getMetadata()

    metadata getter

  getSampleMetadata()

    Read the sample metadata fields and put them in the dictionary

  getSourceMetadata()

    Read the source metadata fields and put them in the dictionary

  onConvert()

    Call the conversion method (and update DataExplorer with converted data)?

  onHelp()

    Display online help related to the file converter

  onIFileOpen()

    Show the path chooser for file with I

  onInputFormat()

    Enable/disable UI items based on input format spec

  onNewFile()

    show the save new file widget

  onNewFileEdited()

    Update the output file state on direct field edit

  onQFileOpen()

    Show the path chooser for file with Q

  openFile()

    Show the path chooser for existent file

  readMetadata()

    Read the metadata fields and put them in the dictionary

    This reads the UI elements directly, but we don’t have a clear MVP distinction in this widgets, so there.

  setValidators()

    Apply validators for double precision numbers to numerical fields

  staticMetaObject = PySide6.QtCore.QMetaObject("FileConverterWidget" inherits "QDialog": )
  updateConvertState()

    Asserts presece of files for coversion. If all present -> enable the Convert button.

## sas.qtgui.Utilities.FrameSelect module

FrameSelect class describes behaviour of the FrameSelect dialog

class sas.qtgui.Utilities.FrameSelect.FrameSelect(parent=None, frames=1, isBSL=True)

  Bases: `QDialog`, `Ui_FrameSelect`

  Class to describe the behaviour of the Frame Selector widget

  addSlots()

    Describe behaviour of OK and Cancel buttons

  addState()

    Minor bookkeeping

  addText()

    Initialize view

  getFrames()

    Accessor for state values

  onFirstChanged()

    Manage view-model sync

  onIncrementChanged()

    Manage view-model sync

  onLastChanged()

    Manage view-model sync

  staticMetaObject = PySide6.QtCore.QMetaObject("FrameSelect" inherits "QDialog": )
  updateDisplay()

    manage model-view sync

## sas.qtgui.Utilities.GenericReader module

Thread handler used to load data

class sas.qtgui.Utilities.GenericReader.GenReader(path, loader, completefn=None, updatefn=None, yieldtime=0.01, worktime=0.01)

  Bases: `CalcThread`

  Load a sld data given a filename

  compute()

    Read some data

  isquit()

    @raise KeyboardInterrupt: when the thread is interrupted

## sas.qtgui.Utilities.GridPanel module

class sas.qtgui.Utilities.GridPanel.BatchInversionOutputPanel(parent=None, output_data=None)

  Bases: `BatchOutputPanel`

  Class for stateless grid-like printout of P(r) parameters for any number of data sets

  closeEvent(event)

    Tell the parent window the window closed

  newTableTab(tab_name=None, data=None)
  onHelp()

    Open a local url in the default browser

  onPlot()

    Plot selected fits by sending signal to the parent

  setupTable(widget=None, data=None)

    Create tablewidget items and show them, based on params

  staticMetaObject = PySide6.QtCore.QMetaObject("BatchInversionOutputPanel" inherits "BatchOutputPanel": )

class sas.qtgui.Utilities.GridPanel.BatchOutputPanel(parent=None, output_data=None)

  Bases: `QMainWindow`, `Ui_GridPanelUI`

  Class for stateless grid-like printout of model parameters for multiple models

  ERROR_COLUMN_CAPTION = ' (Err)'
  IS_WIN = False
  actionLoadData()

    Open file load dialog and load a .csv file

  actionSaveFile()

    Generate a .csv file and dump it to disk

  actionSendToExcel()

    Generates a .csv file and opens the default CSV reader

  addFitResults(results)

    Create a new tab with batch results

  addTabPage(name=None)

    Add new tab page with QTableWidget

  addToolbarActions()

    Assing actions and callbacks to the File menu items

  closeEvent(event)

    Overwrite QDialog close method to allow for custom widget close

  closeTab(currentIndex)
  currentTable()

    Returns the currently shown QTabWidget

  classmethod dataFromTable(table)

    Creates a dictionary {<parameter>:[list of values]} from the parameter table

  onHelp()

    Open a local url in the default browser

  onPlot()

    Plot selected fits by sending signal to the parent

  setupTable(widget=None, data=None)

    Create tablewidget items and show them, based on params

  setupTableFromCSV(csv_data)

    Create tablewidget items and show them, based on params

  showContextMenu(position)

    Show context specific menu in the tab table widget.

  staticMetaObject = PySide6.QtCore.QMetaObject("BatchOutputPanel" inherits "QMainWindow": Methods: #39 type=Signal, signature=windowClosedSignal() )
  windowClosedSignal
  classmethod writeBatchToFile(data, tmpfile, details='')

    Helper to write result from batch into cvs file

## sas.qtgui.Utilities.GuiUtils module

Global defaults and various utility functions usable by the general GUI

class sas.qtgui.Utilities.GuiUtils.Communicate

  Bases: `QObject`

  Utility class for tracking of the Qt signals

  SaveFitParamsSignal
  activeGraphName
  activeGraphsSignal
  changeDataExplorerTabSignal
  closeSignal
  copyExcelFitParamsSignal
  copyFitParamsSignal
  copyLatexFitParamsSignal
  customModelDirectoryChanged
  dataDeletedSignal
  deleteIntermediateTheoryPlotsSignal
  extMaskEditorSignal
  fileDataReceivedSignal
  fileReadSignal
  forcePlotDisplaySignal
  maskEditorSignal
  pasteFitParamsSignal
  perspectiveChangedSignal
  plotFromNameSignal
  plotRequestedSignal
  plotUpdateSignal
  progressBarUpdateSignal
  resultPlotUpdateSignal
  sendDataToGridSignal
  sendDataToPanelSignal
  staticMetaObject = PySide6.QtCore.QMetaObject("Communicate" inherits "QObject": Methods: #4 type=Signal, signature=fileReadSignal(QVariantList), parameters=QVariantList #5 type=Signal, signature=fileDataReceivedSignal(QVariantMap), parameters=QVariantMap #6 type=Signal, signature=statusBarUpdateSignal(QString), parameters=QString #7 type=Signal, signature=updatePerspectiveWithDataSignal(QVariantList), parameters=QVariantList #8 type=Signal, signature=updateModelFromPerspectiveSignal(QStandardItem*), parameters=QStandardItem* #9 type=Signal, signature=updateTheoryFromPerspectiveSignal(QStandardItem*), parameters=QStandardItem* #10 type=Signal, signature=deleteIntermediateTheoryPlotsSignal(QString), parameters=QString #11 type=Signal, signature=plotRequestedSignal(QVariantList,int), parameters=QVariantList, int #12 type=Signal, signature=plotFromNameSignal(QString), parameters=QString #13 type=Signal, signature=plotUpdateSignal(QVariantList), parameters=QVariantList #14 type=Signal, signature=progressBarUpdateSignal(int), parameters=int #15 type=Signal, signature=activeGraphsSignal(QVariantList), parameters=QVariantList #16 type=Signal, signature=activeGraphName(PyObject), parameters=PyObject #17 type=Signal, signature=perspectiveChangedSignal(QString), parameters=QString #18 type=Signal, signature=dataDeletedSignal(QVariantList), parameters=QVariantList #19 type=Signal, signature=sendDataToPanelSignal(QVariantMap), parameters=QVariantMap #20 type=Signal, signature=updateModelFromDataOperationPanelSignal(QStandardItem*,QVariantMap), parameters=QStandardItem*, QVariantMap #21 type=Signal, signature=customModelDirectoryChanged() #22 type=Signal, signature=sendDataToGridSignal(QVariantList), parameters=QVariantList #23 type=Signal, signature=maskEditorSignal(PyObject), parameters=PyObject #24 type=Signal, signature=extMaskEditorSignal() #25 type=Signal, signature=copyFitParamsSignal(QString), parameters=QString #26 type=Signal, signature=copyExcelFitParamsSignal(QString), parameters=QString #27 type=Signal, signature=copyLatexFitParamsSignal(QString), parameters=QString #28 type=Signal, signature=SaveFitParamsSignal(QString), parameters=QString #29 type=Signal, signature=pasteFitParamsSignal() #30 type=Signal, signature=updateModelCategoriesSignal() #31 type=Signal, signature=changeDataExplorerTabSignal(int), parameters=int #32 type=Signal, signature=resultPlotUpdateSignal(QVariantList), parameters=QVariantList #33 type=Signal, signature=forcePlotDisplaySignal(QVariantList), parameters=QVariantList #34 type=Signal, signature=updateMaskedDataSignal() #35 type=Signal, signature=closeSignal() )
  statusBarUpdateSignal
  updateMaskedDataSignal
  updateModelCategoriesSignal
  updateModelFromDataOperationPanelSignal
  updateModelFromPerspectiveSignal
  updatePerspectiveWithDataSignal
  updateTheoryFromPerspectiveSignal

class sas.qtgui.Utilities.GuiUtils.DoubleValidator

  Bases: `QDoubleValidator`

  Allow only dots as decimal separator

  fixup(input)

    Correct (remove) potential preexisting content

  staticMetaObject = PySide6.QtCore.QMetaObject("DoubleValidator" inherits "QDoubleValidator": )
  validate(input, pos)

    Return invalid for commas

class sas.qtgui.Utilities.GuiUtils.FormulaValidator(parent=None)

  Bases: `QValidator`

  staticMetaObject = PySide6.QtCore.QMetaObject("FormulaValidator" inherits "QValidator": )
  validate(input, pos)

class sas.qtgui.Utilities.GuiUtils.HashableStandardItem(parent=None)

  Bases: `QStandardItem`

  Subclassed standard item with reimplemented __hash__ to allow for use as an index.

  clone()

    Assure __hash__ is cloned as well

sas.qtgui.Utilities.GuiUtils.checkModel(path)

  Check that the model save in file ‘path’ can run.

sas.qtgui.Utilities.GuiUtils.convertFromSVS(datasets)

  Read in properties from SVS and convert into a simple dict

sas.qtgui.Utilities.GuiUtils.convertUnitToHTML(unit)

  Convert ASCII unit display into HTML symbol

sas.qtgui.Utilities.GuiUtils.createModelItemWithPlot(update_data, name='')

  Creates a checkboxed QStandardItem named “name” Adds ‘update_data’ to that row.

sas.qtgui.Utilities.GuiUtils.dataFromItem(item)

  Retrieve Data1D/2D component from QStandardItem. The assumption - data stored in SasView standard, in child 0

sas.qtgui.Utilities.GuiUtils.deleteRedundantPlots(item, new_plots)

  Checks all plots that are children of the given item; if any have an ID or name not included in new_plots, it is deleted. Useful for e.g. switching from P(Q)S(Q) to P(Q); this would remove the old S(Q) plot.

  Ensure that new_plots contains ALL the relevant plots(!!!)

sas.qtgui.Utilities.GuiUtils.enum(*sequential, **named)

  Create an enumeration object from a list of strings

sas.qtgui.Utilities.GuiUtils.findNextFilename(filename, directory)

  Finds the next available (non-existing) name for ‘filename’ in ‘directory’. plugin.py -> plugin (n).py - for first ‘n’ for which the file doesn’t exist

sas.qtgui.Utilities.GuiUtils.formatNumber(value, high=False)

  Return a float in a standardized, human-readable formatted string. This is used to output readable (e.g. x.xxxe-y) values to the panel.

sas.qtgui.Utilities.GuiUtils.formatValue(value)

  Formats specific data types for the GUI.

  This function accepts three types of data: numeric data castable to float, a numpy.ndarray of type castable to float, or None. Numeric data is returned in human-readable format by formatNumber(), numpy arrays are averaged over all axes, and the mean returned in human-readable format. If value=None then the string “NaN” is returned.

  Parameters:

    value (float, numeric type castable to float, numpy.ndarray, None) – The value to be formatted

  Returns:

    The formatted value

  Return type:

    str

sas.qtgui.Utilities.GuiUtils.getChildrenFromItem(root)

  Recursively go down the model item looking for all children

sas.qtgui.Utilities.GuiUtils.getConstraints(fit_project)

  Extracts constraints from fir_project dict and returns a dict where keys are the tab name and values are a list of constraints on that tab. The dict can then be passed to the updateFromConstraints method from the fitting perspective to apply the constraints with error checking mechanism

sas.qtgui.Utilities.GuiUtils.getMonospaceFont()

  Convenience function; returns a monospace font to be used in any shells, code editors, etc.

sas.qtgui.Utilities.GuiUtils.get_sensible_default_open_directory()
  Returns:

    app_path - the path to the application directory

sas.qtgui.Utilities.GuiUtils.infoFromData(data)

  Given Data1D/Data2D object, extract relevant Info elements and add them to a model item

sas.qtgui.Utilities.GuiUtils.itemFromDisplayName(name, model_item)

  Returns the model item text=name in the model

sas.qtgui.Utilities.GuiUtils.onTXTSave(data, path)

  Save file as formatted txt

sas.qtgui.Utilities.GuiUtils.openLink(url)

  Open a URL in an external browser. Check the URL first, though.

sas.qtgui.Utilities.GuiUtils.parseName(name, expression)

  remove “_” in front of a name

sas.qtgui.Utilities.GuiUtils.plotsFromCheckedItems(model_item)

  Returns the list of plots for items in the model which are checked

sas.qtgui.Utilities.GuiUtils.plotsFromDisplayName(name, model_item)

  Returns the list of plots for the item with text=name in the model

sas.qtgui.Utilities.GuiUtils.plotsFromModel(model_name, model_item)

  Returns the list of plots for the item with model name in the model

sas.qtgui.Utilities.GuiUtils.plotsOfType(model, datatype=<class 'sas.qtgui.Plotting.PlotterData.Data1D'>)

  Returns the list of plots for the whole model of type datatype

sas.qtgui.Utilities.GuiUtils.readDataFromFile(fp)

  Reads in Data1D/Data2 datasets from the file. Datasets are stored in the JSON format.

sas.qtgui.Utilities.GuiUtils.readProjectFromSVS(filepath)

  Read old SVS file and convert to the project dictionary

sas.qtgui.Utilities.GuiUtils.replaceHTMLwithASCII(html)

  Replace some important HTML-encoded characters with their ASCII equivalents

sas.qtgui.Utilities.GuiUtils.replaceHTMLwithUTF8(html)

  Replace some important HTML-encoded characters with their UTF-8 equivalents

sas.qtgui.Utilities.GuiUtils.retrieveData1d(data)

  Retrieve 1D data from file and construct its text representation

sas.qtgui.Utilities.GuiUtils.retrieveData2d(data)

  Retrieve 2D data from file and construct its text representation

sas.qtgui.Utilities.GuiUtils.rstToHtml(s)

sas.qtgui.Utilities.GuiUtils.saveAnyData(data, wildcard_dict=None)

  Generic file save routine called by SaveData1D and SaveData2D

  Parameters:

    - data – Data 1D or Data2D object the data will be taken from

    - wildcard_dict – Dictionary in format {“Display Text”: “.ext”}

sas.qtgui.Utilities.GuiUtils.saveData(fp, data)

  save content of data to fp (a .write()-supporting file-like object)

sas.qtgui.Utilities.GuiUtils.saveData1D(data)

  Save 1D data points

  Parameters:

    data – Data1D object the data will be taken from

sas.qtgui.Utilities.GuiUtils.saveData2D(data)

  Save data2d data points

  Parameters:

    data – Data2D object the data will be taken from

sas.qtgui.Utilities.GuiUtils.showHelp(url: Path | str | PathLike[str])

sas.qtgui.Utilities.GuiUtils.toDouble(value_string)

  toFloat conversion which cares deeply about user’s locale

sas.qtgui.Utilities.GuiUtils.updateModelItem(item, update_data, name='')

  Adds a simple named child to QStandardItem

sas.qtgui.Utilities.GuiUtils.updateModelItemStatus(model_item, filename='', name='', status=2)

  Update status of checkbox related to high- and low-Q extrapolation choice in Invariant Panel

sas.qtgui.Utilities.GuiUtils.updateModelItemWithPlot(item, update_data, name='', checkbox_state=None)

  Adds a checkboxed row named “name” to QStandardItem Adds ‘update_data’ to that row.

sas.qtgui.Utilities.GuiUtils.xyTransform(data, xLabel='', yLabel='')

  Transforms x and y in View and set the scale

## sas.qtgui.Utilities.HidableDialog module

class sas.qtgui.Utilities.HidableDialog.HidableDialog(window_title: str, message: str, parent=None, buttons=None)

  Bases: `QDialog`

  Dialog class with an ‘ask me again’ feature

  property show_again: bool
  staticMetaObject = PySide6.QtCore.QMetaObject("HidableDialog" inherits "QDialog": )

class sas.qtgui.Utilities.HidableDialog.ShowAgainResult(result: bool, ask_again: bool)

  Bases: `NamedTuple`

  Data structure for the output of the hidable dialog

  ask_again: bool

    Alias for field number 1

  result: bool

    Alias for field number 0

sas.qtgui.Utilities.HidableDialog.hidable_dialog(window_title: str, message: str, show: bool, parent=None, buttons=None) → ShowAgainResult

  A dialog with an ask again feature.

sas.qtgui.Utilities.HidableDialog.main()

## sas.qtgui.Utilities.IPythonWidget module

class sas.qtgui.Utilities.IPythonWidget.IPythonWidget(**kwargs: Any)

  Bases: `RichJupyterWidget`

  staticMetaObject = PySide6.QtCore.QMetaObject("IPythonWidget" inherits "RichJupyterWidget": )

## sas.qtgui.Utilities.ImageViewer module

Image viewer widget.

class sas.qtgui.Utilities.ImageViewer.ImageViewer(parent=None)

  Bases: `QMainWindow`, `Ui_ImageViewerUI`

  Implemented as QMainWindow to enable easy menus

  actionConvertToData()

    Show the options dialog and if accepted, send data to conversion

  actionCopyImage()

    Copy MPL widget area to buffer

  actionHowTo()

    Send the image viewer help URL to the help viewer

  actionLoadImage()

    Image loader given files extensions

  actionPrintImage()

    Display printer dialog and print the MPL widget area

  actionSaveImage()

    Use the internal MPL method for saving to file

  addPlotter()

    Add a new plotter to the frame

  addTriggers()

    Trigger definitions for all menu/toolbar actions.

  convertImage(rgb, xmin, xmax, ymin, ymax, zscale)

    Convert image to data2D

  disableMenus()

    All menu items but “Load File” and “Help” should be disabled when no data is present

  enableMenus()

    Enable all menu items when data is present

  rgb2gray(rgb)

    RGB to Grey

  showImage(filename)

    Show the requested image in the main frame

  staticMetaObject = PySide6.QtCore.QMetaObject("ImageViewer" inherits "QMainWindow": )

class sas.qtgui.Utilities.ImageViewer.ImageViewerOptions(parent=None)

  Bases: `QDialog`, `Ui_ImageViewerOptionsUI`

  Logics for the image viewer options UI

  addDefaults()

    Fill out textedits with default values

  addValidators()

    Define simple validators on line edits

  getState()

    return current state of the widget

  staticMetaObject = PySide6.QtCore.QMetaObject("ImageViewerOptions" inherits "QDialog": )

## sas.qtgui.Utilities.ObjectLibrary module

sas.qtgui.Utilities.ObjectLibrary.addObject(obj_name, obj)

sas.qtgui.Utilities.ObjectLibrary.deleteObjectByName(obj_name)

sas.qtgui.Utilities.ObjectLibrary.deleteObjectByRef(obj)

sas.qtgui.Utilities.ObjectLibrary.getObject(obj_name)

sas.qtgui.Utilities.ObjectLibrary.listObjects()

## sas.qtgui.Utilities.PlotView module

class sas.qtgui.Utilities.PlotView.ConvergenceView(**kw)

  Bases: `FitResultView`

  plot()
  staticMetaObject = PySide6.QtCore.QMetaObject("ConvergenceView" inherits "FitResultView": )

class sas.qtgui.Utilities.PlotView.CorrelationView(**kw)

  Bases: `FitResultView`

  plot()
  staticMetaObject = PySide6.QtCore.QMetaObject("CorrelationView" inherits "FitResultView": )

class sas.qtgui.Utilities.PlotView.FitResultView(**kw)

  Bases: `QWidget`

  plot()
  show_plot_selector = False
  state = None
  staticMetaObject = PySide6.QtCore.QMetaObject("FitResultView" inherits "QWidget": )
  update(state)

class sas.qtgui.Utilities.PlotView.TraceView(**kw)

  Bases: `FitResultView`

  plot()
  show_plot_selector = True
  staticMetaObject = PySide6.QtCore.QMetaObject("TraceView" inherits "FitResultView": )
  update(state)

class sas.qtgui.Utilities.PlotView.UncertaintyView(**kw)

  Bases: `FitResultView`

  plot()
  staticMetaObject = PySide6.QtCore.QMetaObject("UncertaintyView" inherits "FitResultView": )

sas.qtgui.Utilities.PlotView.plot_convergence(pop, best, fig)

## sas.qtgui.Utilities.PluginManager module

class sas.qtgui.Utilities.PluginManager.PluginManager(parent=None)

  Bases: `QDialog`, `Ui_PluginManagerUI`

  Class describing the model plugin manager. This is a simple list widget allowing for viewing/adding/deleting custom models.

  addSignals()

    Define slots for widget signals

  onAdd()

    Show the add new model dialog

  onAddFile()

    Open system Load FIle dialog, load a plugin and put it in the plugin directory

  onDelete()

    Remove the file containing the selected plugin

  onDuplicate()

    Creates a copy of the selected model(s)

  onEdit()

    Show the edit existing model dialog

  onHelp()

    Show the help page in the default browser

  onSelectionChanged()

    Respond to row selection

  readModels()

    Read in custom models from the default location

  staticMetaObject = PySide6.QtCore.QMetaObject("PluginManager" inherits "QDialog": )

## sas.qtgui.Utilities.PythonSyntax module

class sas.qtgui.Utilities.PythonSyntax.PythonHighlighter(document, is_python=True)

  Bases: `QSyntaxHighlighter`

  Syntax highlighter for the Python language.

  braces = ['\\{', '\\}', '\\(', '\\)', '\\[', '\\]']
  c_keywords = ['auto', 'break', 'case', 'char', 'const', 'continue', 'default', 'do', 'double', 'else', 'enum', 'extern', 'float', 'for', 'goto', 'if', 'int', 'long', 'register', 'return', 'short', 'signed', 'sizeof', 'static', 'struct', 'switch', 'typedef', 'union', 'unsigned', 'void', 'volatile', 'while']
  highlightBlock(text)

    Apply syntax highlighting to the given block of text.

  match_multiline(text, delimiter, in_state, style)

    Do highlighting of multi-line strings. `delimiter` should be a `QRegExp` for triple-single-quotes or triple-double-quotes, and `in_state` should be a unique integer to represent the corresponding state changes when inside those strings. Returns True if we’re still inside a multi-line string when this function is finished.

  operators = ['=', '==', '!=', '<', '<=', '>', '>=', '\\+', '-', '\\*', '/', '//', '\\%', '\\*\\*', '\\+=', '-=', '\\*=', '/=', '\\%=', '\\^', '\\|', '\\&', '\\~', '>>', '<<']
  python_keywords = ['and', 'assert', 'break', 'class', 'continue', 'def', 'del', 'elif', 'else', 'except', 'exec', 'finally', 'for', 'from', 'global', 'if', 'import', 'in', 'is', 'lambda', 'not', 'or', 'pass', 'print', 'raise', 'return', 'try', 'while', 'yield', 'None', 'True', 'False']
  staticMetaObject = PySide6.QtCore.QMetaObject("PythonHighlighter" inherits "QSyntaxHighlighter": )

sas.qtgui.Utilities.PythonSyntax.format(color, style='')

  Return a QTextCharFormat with the given attributes.

## sas.qtgui.Utilities.ReactorCore module

This module provides support for Twisted to be driven by the Qt mainloop.

In order to use this support, simply do the following::
  app = QApplication(sys.argv) # your code to init Qt
  import qt5reactor
  qt5reactor.install()

Then use twisted.internet APIs as usual. The other methods here are not intended to be called directly.

If you don’t instantiate a QApplication or QCoreApplication prior to installing the reactor, a QCoreApplication will be constructed by the reactor. QCoreApplication does not require a GUI so trial testing can occur normally.

Twisted can be initialized after QApplication.exec_() with a call to reactor.runReturn(). calling reactor.stop() will unhook twisted but leave your Qt application running

Qt5 Port: U{Burak Nehbit<mailto:burak@nehbit.net>}

Current maintainer: U{Christopher R. Wood<mailto:chris@leastauthority.com>}

Previous maintainer: U{Tarashish Mishra<mailto:sunu@sunu.in>} Previous maintainer: U{Glenn H Tarbox, PhD<mailto:glenn@tarbox.org>} Previous maintainer: U{Itamar Shtull-Trauring<mailto:twisted@itamarst.org>} Original port to QT4: U{Gabe Rudy<mailto:rudy@goldenhelix.com>} Subsequent port by therve

sas.qtgui.Utilities.ReactorCore.install()

  Install the Qt reactor.

## sas.qtgui.Utilities.ResultPanel module

FitPanel class contains fields allowing to fit models and data

class sas.qtgui.Utilities.ResultPanel.ResultPanel(parent, manager=None, *args, **kwargs)

  Bases: `QTabWidget`

  FitPanel class contains fields allowing to fit models and data

  Note:

    For Fit to be performed the user should check at least one parameter on fit Panel window.

  clearAnyData()

    Clear any previous results and reset window to its base state.

  closeEvent(event)

    Overwrite QDialog close method to allow for custom widget close

  onDataDeleted(data)

    Check if the data set is shown in the window and close tabs as needed.

  onPlotResults(results, optimizer='Unknown')
  staticMetaObject = PySide6.QtCore.QMetaObject("ResultPanel" inherits "QTabWidget": Methods: #39 type=Signal, signature=windowClosedSignal() )
  windowClosedSignal
  window_name = 'Result panel'

## sas.qtgui.Utilities.SasviewLogger module

class sas.qtgui.Utilities.SasviewLogger.QtHandler

  Bases: `Handler`

  Emit python log messages through a Qt signal. Receivers can connect to handler.postman.messageWritten with a method accepting the formatted log entry produced by the logger.

  emit(record)

    Do whatever it takes to actually log the specified logging record.

    This version is intended to be implemented by subclasses and so raises a NotImplementedError.

class sas.qtgui.Utilities.SasviewLogger.QtPostman

  Bases: `QObject`

  messageWritten
  staticMetaObject = PySide6.QtCore.QMetaObject("QtPostman" inherits "QObject": Methods: #4 type=Signal, signature=messageWritten(PyObject), parameters=PyObject )

class sas.qtgui.Utilities.SasviewLogger.SasViewLogFormatter(fmt=None, datefmt=None, style='%', validate=True, *, defaults=None)

  Bases: `Formatter`

  DATE_FORMAT = '%H:%M:%S'
  LOG_COLORS = {'CRITICAL': 'red', 'ERROR': 'red', 'WARNING': 'orange'}
  LOG_FORMAT = '%(asctime)s - <b{}>%(levelname)s</b>: %(message)s'
  format(record)

    Give extra formatting on error messages

sas.qtgui.Utilities.SasviewLogger.setup_qt_logging()

## Module contents