scanometrics.GUI.CheckBox package

Submodules

scanometrics.GUI.CheckBox.CheckBox module

class scanometrics.GUI.CheckBox.CheckBox.CheckBox(label)

Bases: QWidget

emit_signal(state)

Slot that gets called when the checkbox state changes. Emits the valueChanged signal with the checkbox’s label only if the checkbox is checked.

is_checked()

Method to check the current state of the checkbox. :return: True if the checkbox is checked, otherwise False.

set_checked(checked)

Method to programmatically set the checkbox state. :param checked: Boolean indicating whether the checkbox should be checked (True) or not (False).

sgn

pyqtSignal(*types, name: str = …, revision: int = …, arguments: Sequence = …) -> PYQT_SIGNAL

types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.

scanometrics.GUI.CheckBox.MetricCheckBox module

class scanometrics.GUI.CheckBox.MetricCheckBox.MetricCheckBox

Bases: QWidget

fill_layout(widgets_info)

Helper method to fill the specified layout with widgets.

Args:
widgets_info (list): List of tuples containing widget information:

(widget_name, widget, widget_style, signal_label, layout_position)

get_selected_value()

Return the currently selected checkbox value.

handle_sgn(sgn_value)

Handle the signal emitted by the checkboxes and store the selected value.

Args:

sgn_value (str): The value of the checkbox that was checked.

reset_checkboxes()

Reset all checkboxes except the one with the current value.

sgn

pyqtSignal(*types, name: str = …, revision: int = …, arguments: Sequence = …) -> PYQT_SIGNAL

types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.