Skip to main content

Lightweight framework based on PySide6 to quickly build modern desktop applications, with integrated resource, theme, and reusable component management.

Project description

๐Ÿš€ EzQt App

Python Platform Version PyPI Docs License Status Tests

EzQt Widgets Logo

EzQt App is a lightweight Python framework based on PySide6 to quickly build modern desktop applications, with integrated resource, theme, translation, and reusable component management. Built on a hexagonal architecture for clean separation of concerns.

๐Ÿ“ฆ Installation

pip install ezqt-app

Or from source:

git clone https://github.com/neuraaak/ezqt-app.git
cd ezqt-app && pip install .

๐Ÿš€ Quick Start

import sys
from ezqt_app.app import EzQt_App
from ezqt_app.services.application.app_service import AppService

# Initialize and run the framework
app_service = AppService()
app_service.initialize()

# Create main window
window = EzQt_App(themeFileName="main_theme.qss")

# Add navigation menus
home_page = window.addMenu("Home", "๐Ÿ ")
settings_page = window.addMenu("Settings", "โš™๏ธ")

# Show application
window.show()
app_service.exec()

๐ŸŽฏ Key Features

  • โœ… PySide6 Compatible: Full support for the latest PySide6 versions
  • โœ… Hexagonal Architecture: Clean domain/services/widgets separation
  • โœ… Full Type Hints: Complete typing support for IDEs and linters
  • โœ… Dynamic Themes: Light/dark themes with integrated toggle via QSS
  • โœ… Global Translation: Multi-language support (EN, FR, ES, DE)
  • โœ… Automatic Translation: Non-blocking multi-provider system (Google, MyMemory, LibreTranslate) with daemon-thread HTTP, in-flight deduplication, and progressive .ts/.qm file population
  • โœ… CLI Tools: Project initialization, template generation, and management
  • โœ… Template System: Basic and advanced project scaffolding
  • โœ… Standardized Logging: Consistent message formatting across all components
  • โœ… Comprehensive Tests: Complete test suite (~426 tests)

๐Ÿ“š Documentation

Full documentation is available online: neuraaak.github.io/ezqt-app

๐Ÿ—๏ธ Architecture

EzQt App follows a hexagonal architecture with three main layers:

src/ezqt_app/
โ”œโ”€โ”€ domain/          # Contracts, ports, models, errors (no dependencies)
โ”‚   โ”œโ”€โ”€ ports/       # Abstract interfaces (AppPort, ConfigPort, etc.)
โ”‚   โ”œโ”€โ”€ models/      # Domain models
โ”‚   โ””โ”€โ”€ errors/      # Domain exceptions
โ”œโ”€โ”€ services/        # Adapters implementing domain ports
โ”‚   โ”œโ”€โ”€ application/ # App lifecycle (AppService, InitService)
โ”‚   โ”œโ”€โ”€ config/      # Configuration (ConfigService, SettingsService)
โ”‚   โ”œโ”€โ”€ translation/ # i18n (TranslationService, AutoTranslator)
โ”‚   โ””โ”€โ”€ ui/          # UI coordination (ThemeService, MenuService)
โ”œโ”€โ”€ widgets/         # PySide6 presentation layer
โ”‚   โ”œโ”€โ”€ core/        # Header, Menu, PageContainer
โ”‚   โ””โ”€โ”€ extended/    # SettingWidgets and advanced components
โ”œโ”€โ”€ shared/          # Cross-cutting utilities
โ”œโ”€โ”€ cli/             # Command-line interface
โ””โ”€โ”€ app.py           # Main EzQt_App entry point

๐Ÿงฉ Available Components

๐Ÿ”ง Application Services (ezqt_app.services)

Service Description
AppService Application lifecycle management
InitService Startup initialization and bootstrap
ConfigService Application configuration management
SettingsService User settings persistence
RuntimeStateService Runtime state tracking
TranslationService Language management and switching
ThemeService Theme loading and switching
MenuService Navigation menu management
WindowService Main window orchestration

๐ŸŒ Translation System (ezqt_app.services.translation)

Component Description
TranslationManager Central translation registry, .ts/.qm lifecycle
EzTranslator Qt interceptor โ€” feeds unknown strings to auto-translation
AutoTranslator Non-blocking multi-provider translation (daemon threads)
StringCollector Automatic string discovery for translation

๐ŸŽจ Widgets (ezqt_app.widgets)

Widget Description
EzQt_App Main application window with modern UI
Header Top navigation bar with title and controls
Menu Sidebar navigation menu
PageContainer Content area manager
SettingWidgets Settings UI components with validation

๐Ÿงช Testing

Comprehensive test suite with 426+ test cases covering services, widgets, and integration scenarios.

# Install dev dependencies
pip install -e ".[dev]"

# Run all tests
pytest tests/

# Run by marker
pytest tests/ -m unit
pytest tests/ -m integration

# With coverage
pytest tests/ --cov=src/ezqt_app --cov-report=html

# Using CLI
ezqt test --unit
ezqt test --coverage

See the Testing Guide for complete details.

๐Ÿ–ฅ๏ธ CLI Commands

Project Management

# Initialize new project (assets, QRC, resources)
ezqt init [--force] [--verbose] [--no-main]

# Create project from template
ezqt create --template basic --name my_app
ezqt create --template advanced --name my_app

# Show project information
ezqt info

Development Tools

# Convert .ts translation files to .qm
ezqt convert [--verbose]
ezqt mkqm [--verbose]

# Run tests
ezqt test [--unit] [--integration] [--coverage]

# Serve documentation
ezqt docs [--serve] [--port <port>]

๐ŸŒ Translation System

# Use Qt's standard translation call โ€” EzTranslator intercepts automatically
from PySide6.QtCore import QCoreApplication
text = QCoreApplication.translate("EzQt_App", "Hello World")

# Change active language (triggers LanguageChange on all widgets)
from ezqt_app.services.translation import get_translation_manager
get_translation_manager().load_language("Franรงais")

# Enable auto-translation: unknown strings are translated via external providers
# and progressively saved to .ts files, then compiled to .qm
window.enable_auto_translation(True)

Supported languages: English, Franรงais, Espaรฑol, Deutsch Translation providers: Google Translate, MyMemory, LibreTranslate (tried in order, daemon threads โ€” UI never blocked) Auto-populate: .ts files are updated at runtime; .qm files are recompiled via pyside6-lrelease on each language load. Identity entries are written for the source language so en.ts is always populated.

๐Ÿ› ๏ธ Development Setup

# Clone and install in development mode
git clone https://github.com/neuraaak/ezqt-app.git
cd ezqt-app
pip install -e ".[dev]"

# Install pre-commit hooks
pre-commit install

# Verify CLI installation
ezqt --version
ezqt info

See the Development Guide for detailed instructions.

๐Ÿ“ฆ Dependencies

Runtime

  • PySide6>=6.7.3 โ€“ Qt for Python framework
  • requests>=2.32.4 โ€“ HTTP requests (translation providers)
  • click>=8.2.1 โ€“ CLI framework
  • PyYAML>=6.0 โ€“ YAML configuration
  • ruamel.yaml==0.18.6 โ€“ Advanced YAML processing

Development

  • pytest>=7.0.0 โ€“ Testing framework
  • pytest-cov>=4.0.0 โ€“ Coverage reporting
  • ruff>=0.1.0 โ€“ Linting and formatting
  • mypy / pyright โ€“ Type checking

๐Ÿ“„ License

MIT License โ€“ See LICENSE file for details.

๐Ÿ”— Links


EzQt App โ€“ Modern PySide6 application framework with hexagonal architecture. ๐Ÿš€

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ezqt_app-5.2.1.tar.gz (753.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

ezqt_app-5.2.1-py3-none-any.whl (1.0 MB view details)

Uploaded Python 3

File details

Details for the file ezqt_app-5.2.1.tar.gz.

File metadata

  • Download URL: ezqt_app-5.2.1.tar.gz
  • Upload date:
  • Size: 753.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for ezqt_app-5.2.1.tar.gz
Algorithm Hash digest
SHA256 00233cbc8a9ef78e3de0cce148b692bab1c9cc07280ed29254ee1024cc1d8ae7
MD5 445424ed2945000559e7d8d75ccb84bb
BLAKE2b-256 76b21258357cff91bf3672c3c2eff63ae2abcc0fae403111abefe2f86e572389

See more details on using hashes here.

File details

Details for the file ezqt_app-5.2.1-py3-none-any.whl.

File metadata

  • Download URL: ezqt_app-5.2.1-py3-none-any.whl
  • Upload date:
  • Size: 1.0 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for ezqt_app-5.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 ea1d12c428965ce1a09991de86b51c900382ab68fb7f3eeeab8af03cacf6df54
MD5 40d07c92f23ada7ab79d333aca5cbdd4
BLAKE2b-256 2e546fb3e1d5b502417025666de2b071b2c3a5b572ff9b0fcf2a2512599119a2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page