Index: simulator/runtimewidget.py =================================================================== diff -u -r6a5824cc32716947513b4a5adca54a9e513c0c5c -r057afac3dea8ab1243550d0e36cd3ec6eacb993f --- simulator/runtimewidget.py (.../runtimewidget.py) (revision 6a5824cc32716947513b4a5adca54a9e513c0c5c) +++ simulator/runtimewidget.py (.../runtimewidget.py) (revision 057afac3dea8ab1243550d0e36cd3ec6eacb993f) @@ -51,9 +51,18 @@ assert child is not None, "child name '{}' with type '{}' can't be found.".format(child_name, child_type) return child + def find_action(self, name: str) -> QtWidgets.QAction: + """ + convenient method of find_widget for QAction + :param name: (str) name of the QLabel Object + :return: (QAction) reference to the QAction + """ + child = self.find_widget(QtWidgets.QAction, name) + return child + def find_label(self, name: str) -> QtWidgets.QLabel: """ - convenient method of find_child for QLabel + convenient method of find_widget for QLabel :param name: (str) name of the QLabel Object :return: (QLabel) reference to the QLabel """ @@ -62,7 +71,7 @@ def find_button(self, name: str) -> QtWidgets.QPushButton: """ - convenient method of find_child for QPushButton + convenient method of find_widget for QPushButton :param name: (str) name of the QPushButton Object :return: (QPushButton) reference to the QPushButton """ @@ -71,16 +80,16 @@ def find_combobox(self, name: str) -> QtWidgets.QComboBox: """ - convenient method of find_child for QComboBox + convenient method of find_widget for QComboBox :param name: (str) name of the QComboBox Object :return: (QComboBox) reference to the QComboBox """ child = self.find_widget(QtWidgets.QComboBox, name) return child - def find_checkox(self, name: str) -> QtWidgets.QCheckBox: + def find_checkbox(self, name: str) -> QtWidgets.QCheckBox: """ - convenient method of find_child for QCheckBox + convenient method of find_widget for QCheckBox :param name: (str) name of the QCheckBox Object :return: (QCheckBox) reference to the QComboBox """ @@ -89,7 +98,7 @@ def find_spinbox(self, name: str) -> QtWidgets.QSpinBox: """ - convenient method of find_child for QSpinBox + convenient method of find_widget for QSpinBox :param name: (str) name of the QSpinBox Object :return: (QSpinBox) reference to the QSpinBox """ @@ -98,7 +107,7 @@ def find_slider(self, name: str) -> QtWidgets.QSlider: """ - convenient method of find_child for QSlider + convenient method of find_widget for QSlider :param name: (str) name of the QSlider Object :return: (QSlider) reference to the QSlider """ @@ -107,7 +116,7 @@ def find_table_widget(self, name: str) -> QtWidgets.QTableWidget: """ - convenient method of find_child for QTableWidget + convenient method of find_widget for QTableWidget :param name: (str) name of the QTableWidget Object :return: (QTableWidget) reference to the QTableWidget """