autooptions.qtutil module
- class autooptions.qtutil.PlotWidget(viewer: napari.viewer.Viewer)[source]
Bases:
QWidgetA widget that contains a pyplot plot.
- class autooptions.qtutil.TableView(data, *args)[source]
Bases:
QTableWidgetA table that allows to copy the selected cells to the system-clipboard.
- getSelectedDataAsString()[source]
Get the data in the selected cells as a string. Columns are separated by tabs and lines by newlines”.
- class autooptions.qtutil.WidgetTool[source]
Bases:
objectUtility methods for working with qt-widgets.
- static getCheckbox(parent, labelText, defaultValue, fieldWidth, callback)[source]
Answers a label and a checkbox checked or unchecked depeding on the default value.
- Parameters:
parent – The parent widget of the label and the input field
labelText – The text of the label
defaultValue – The boolean default value
fieldWidth – The maximum width of the checkbox
callback – A callback function
- Returns:
A tupel of a label and a checkbox
- static getComboInput(parent, labelText, values, callback=None)[source]
Returns a label displaying the given text and a combo-box with the given values.
- Parameters:
parent – The parent widget of the label and the input field
labelText – The text of the label
values – The values in the list of the combo-box
callback – A callback function that is called with the new text when the selected text changes.
- Returns:
A tupel of the label and the input field
- Return type:
(QLabel, QComboBox)
- static getLineInput(parent, labelText, defaultValue, fieldWidth, callback)[source]
Returns a label displaying the given text and an input field with the given default value.
- Parameters:
parent – The parent widget of the label and the input field
labelText – The text of the label
defaultValue – The value initailly displayed in the input field
fieldWidth – The width of the input field
callback – A callback function with a parameter text. The function is called with the new text when the content of the input field changes
- Returns:
A tupel of the label and the input field
- Return type:
(QLabel, QLineEdit)