mpylab.gui package¶
Shared GUI identity metadata; importing this module does not import Qt.
- class mpylab.gui.ApplicationIdentity(name: str, version: str, description: str, resource_package: str, resource_directory: tuple[str, ...], documentation_url: str, project_url: str, author: str = 'Hans Georg Krauthäuser', license_name: str = 'GPL-3.0-or-later', tagline: str = '')
Bases:
objectApplication-specific content for the optional Qt branding helpers.
- Parameters:
name (str) – Application/menu name.
version (str) – Installed application version.
description (str) – Short user-facing description.
resource_package (str) – Importable package containing the artwork.
resource_directory (tuple of str) – Relative resource-directory components in that package.
documentation_url (str) – Link to maintained user documentation.
project_url (str) – Link to the source project.
author (str) – Copyright attribution.
license_name (str) – Software/artwork license description.
tagline (str) – Accessible artwork description; optional About subtitle.
Notes
The resource directory must provide icon.png, logo.svg and logo-inverse.svg. Keep source attribution and artwork licensing beside those assets.
- author: str = 'Hans Georg Krauthäuser'
- description: str
- documentation_url: str
- license_name: str = 'GPL-3.0-or-later'
- name: str
- project_url: str
- resource_directory: tuple[str, ...]
- resource_package: str
- tagline: str = ''
- version: str
- exception mpylab.gui.MissingGUIError
Bases:
ModuleNotFoundErrorThe optional Qt dependency is missing from the active environment.
- mpylab.gui.require_qt(*, exit_on_missing=False)
Check Qt availability without importing or initializing it.
- Parameters:
exit_on_missing (bool, optional) – Exit a standalone GUI command with an installation hint instead of raising an import exception. Defaults to False for library imports.
- Raises:
MissingGUIError – PySide6 is absent and exit_on_missing is False.
SystemExit – PySide6 is absent and exit_on_missing is True.