A desktop application for generating .docx documents from Excel data with explicit placeholder mapping and optional PDF export via LibreOffice.
The app includes the following localized languages:
- English, Italian, German, Spanish, French, Russian
- Python 3.10+
- LibreOffice (for PDF export functionality)
pip install -r requirements.txtFor development, tests, and packaging:
pip install -r requirements-dev.txtIf you've modified any .ui files in gui/forms/, regenerate the Python form classes:
python scripts/build_ui.pyTo rebuild specific forms:
python scripts/build_ui.py main_window mapping_pagepython main.pyUse PyInstaller to create a standalone executable:
pip install -r requirements-dev.txt
pyinstaller main.specOutput artifact:
- Linux/macOS:
dist/document-mapper - Windows:
dist/document-mapper.exe
The application uses config.toml for configuration. Key settings include:
- Application metadata (name, version, author)
- Window dimensions and theme preferences
- Resource paths for QSS styles, icons, and locales
- Logging configuration
document-mapper/
├── core/ # Core application logic
│ ├── config/ # Configuration management
│ ├── enums/ # Application enums
│ ├── manager/ # Managers (localization, themes)
│ ├── mapping/ # Document mapping services
│ ├── project/ # Project and document models
│ └── util/ # Utility functions
├── gui/ # Graphical user interface
│ ├── controllers/ # UI controllers
│ ├── dialogs/ # Dialog windows
│ ├── forms/ # Qt Designer UI files
│ ├── styles/ # QSS stylesheets
│ ├── ui/ # UI elements
│ └── windows/ # Main application windows
├── resources/ # Application resources
│ ├── icons/ # Application icons
│ ├── locales/ # Translation files
│ └── qss/ # Stylesheets
├── scripts/ # Build and utility scripts
├── tests/ # Test suite
│ ├── core/ # Core logic tests
│ └── gui/ # GUI tests
├── config.toml # Application configuration
├── main.py # Application entry point
├── main.spec # PyInstaller specification
├── pytest.ini # Pytest configuration
├── requirements.txt # Runtime dependencies
└── requirements-dev.txt # Dev/test/build dependencies
This project uses pytest for testing. See tests/README.md for detailed testing instructions.
Quick test run:
python -m pytestFor headless environments:
QT_QPA_PLATFORM=offscreen python -m pytest- Keep runtime dependencies in
requirements.txtonly. - Keep build/test tooling (PyInstaller, pytest) in
requirements-dev.txt. - Install dev tools:
pip install -r requirements-dev.txt - Build executable:
pyinstaller main.spec