.. _MetaControls: MetaControls ============ **class MetaControls(parent: Optional[QWidget] = None)** Bases: :class:`~PySide6.QtWidgets.QWidget` Shared base for the control panels that sit below each analysis tab's plot. Every analysis tab owns a controls widget - ``ClusteringControls``, ``EventAnalysisControls``, ``MetadataControls``, ``ProteinControls`` and ``RawDataControls`` - which builds the tab's comboboxes, buttons and labels and turns user interaction into signals the tab's View connects to. Those five widgets were written by copy-paste and carried the same helpers verbatim; this base holds the shared half so there is one copy to fix. What a subclass inherits: - **Widget factories.** :meth:`createLabel`, :meth:`create_comboBox` and :meth:`createButton` build the three plain widgets every panel uses, with the font, size policy and translation call applied consistently. - **Icon buttons.** :meth:`create_info_button`, :meth:`create_add_button` and :meth:`create_delete_button` build the pencil, plus and trash buttons beside each plugin combobox, already wired to the signals below. - **The placeholder guard.** :meth:`is_placeholder_item` and :meth:`toggle_info_button` keep a combobox's edit and delete buttons disabled until a real plugin is selected, reading the tab's own :attr:`placeholder_texts`. - **Signals.** ``actionTriggered`` carries a request into the tab's Controller as ``(submodel_name, action_name, args)``. ``add_processed``, ``edit_processed`` and ``delete_processed`` carry plugin-management requests, and are emitted for the metaclass whose combobox the user acted on. What a subclass owes it: - **Its own** ``logger = logging.getLogger(__name__)``. This base deliberately declares none, because every call in the family goes through ``self.logger`` and resolves through the MRO - so a logger here would silently re-home every subclass's records to ``poriscope.utils.MetaControls``. - **Its own** :attr:`placeholder_texts`, or the placeholder guard above will read every combobox entry as a real selection. - ``setupUi``, ``connect_signals``, ``validate_inputs`` and ``collect_parameters``, which are genuinely per-tab and are called by the subclass's own ``__init__``. Public Methods -------------- Abstract Methods ~~~~~~~~~~~~~~~~ These methods must be implemented by subclasses. (none) Concrete Methods ~~~~~~~~~~~~~~~~ .. automethod:: poriscope.utils.MetaControls.MetaControls.createButton .. automethod:: poriscope.utils.MetaControls.MetaControls.createLabel .. automethod:: poriscope.utils.MetaControls.MetaControls.create_add_button .. automethod:: poriscope.utils.MetaControls.MetaControls.create_comboBox .. automethod:: poriscope.utils.MetaControls.MetaControls.create_delete_button .. automethod:: poriscope.utils.MetaControls.MetaControls.create_info_button .. automethod:: poriscope.utils.MetaControls.MetaControls.delete_plugin .. automethod:: poriscope.utils.MetaControls.MetaControls.is_placeholder_item .. automethod:: poriscope.utils.MetaControls.MetaControls.show_plugin_add_manager .. automethod:: poriscope.utils.MetaControls.MetaControls.show_plugin_edit_manager .. automethod:: poriscope.utils.MetaControls.MetaControls.toggle_info_button Private Methods --------------- Abstract Methods ~~~~~~~~~~~~~~~~ These methods must be implemented by subclasses. (none)