Contact me in telegram (Most Preferable)

Kazi Rifat Morshed

Undergraduate Student (B.Sc. Engg.) of Computer Science and Engineering (CSE)

MCG Logo

Mass Certificate Generator (MCG)

Personal Project

Automated Bulk Certificate Generation Tool | Maintained on AUR (mass-certificate-generator-bin)

Mass Certificate Generator (MCG) is a modern, high-performance desktop application to generate bulk PDF and image certificates dynamically from CSV or Excel data. Designed for university clubs, conferences, workshops, and educational programs to produce hundreds of customized certificates in seconds!

Arch Linux / Manjaro (AUR)

View on AUR

MCG is packaged natively for Arch Linux users via the Arch User Repository (AUR package):

# Native package (recommended, lightweight)
yay -S mass-certificate-generator-bin
# Or using paru
paru -S mass-certificate-generator-bin

Video Demonstration & Tutorial

Also available on YouTube Playlist: MCG Video Demonstrations

Key Features

1. Tabbed Pipeline Workflow

MCG guides you sequentially through an intuitive setup process:

  • Template Selection: Load any custom PDF certificate template (supports any dimensions and orientations).
  • Coordinate Calibration: Interactively define text boundaries and target positioning on the template using percentage-based bounding coordinates.
  • Font Management: Add and manage custom TrueType (.ttf), OpenType (.otf), and Collection (.ttc) fonts with real-time embedding support.
  • Text Body Configuration: Combine dynamic data layers (mapped to CSV/Excel columns) and static text with individualized fonts, sizes, formatting (Bold, Italic, Underline), and colors.
  • Data Import: Read participant data effortlessly from .csv or .xlsx files with column auto-detection.
  • Export Settings: Choose individual files named by recipient column or a single aggregated multi-page document, with PDF, PNG, and JPEG export formats.

2. Fully Event-Driven & Real-Time Sync

  • Zero Manual "Save" Hassles: Font additions, font renaming, text changes, size tweaks, and style changes update dynamically in real time.
  • Instant Visual Preview: Integrated PDF rendering updates immediately upon any change without manual refreshing.
  • Non-Destructive Font Renaming: Renaming custom fonts updates all dependent text layers automatically without breaking configurations.

3. Robust Font Engine & Fault Tolerance

  • Automatic Embedding Sanitization: Automatically detects and clears OS/2 table embedding restrictions (fsType) in memory/cache to prevent PDF engine substitute-font crashes.
  • TrueType Collection (.ttc) Support: Full parsing and sanitization for multi-font collection files.
  • 3-Tier Rendering Fallback: If custom fonts fail or are missing, MCG automatically falls back to clean HTML styling, followed by standard PDF Base-14 fonts, ensuring export jobs never abort unexpectedly.

4. Non-Destructive Live Debug Mode

  • Visual blue bounding box helps calibrate layout boundaries in the interactive preview without ever appearing in exported PDF/image files.

5. Multi-Platform Session State Persistence

  • Automatic State Recovery: The entire workspace (loaded templates, coordinate boxes, custom font registries, text blocks, data sources, and export preferences) is saved to standard OS user data directories (mcg_session_state.json).
  • Debounced Disk I/O: State saves are debounced to guarantee zero input lag during typing.
  • Safe Migration: Automatically detects and migrates legacy session files.

Running & Building from Source

Prerequisites: Python 3.9+ (Python 3.10 – 3.13 recommended) and pip package manager.

1. Clone & Setup Virtual Environment

git clone https://github.com/KaziRifatMorshed/Mass-Certificate-Generator-MCG-gh-Public.git
cd Mass-Certificate-Generator-MCG-gh-Public/MassCertificateGenerator-MCG
python3 -m venv .venv
source .venv/bin/activate # On Linux/macOS
# .venv\Scripts\activate # On Windows
pip install -r requirements.txt

2. Run Application

python main.py

3. Build Standalone Binaries (Nuitka / PyInstaller)

# Build standalone binary with Nuitka (recommended)
python build_package.py
# Or build with PyInstaller
python build_package.py pyinstaller
# On Windows (with Inno Setup 6 support for installer)
build_windows.bat

Roadmap

Change Debug Mode (Preview-only, non-destructive export)
Single Combined File Output
Individual File Output with dynamic file naming
Dynamic Paper Size & Orientation (any PDF dimensions)
Multi-format export (PDF, PNG, JPEG)
Fully event-driven font and text sync (no manual save buttons)
Automated font embedding restriction sanitization (.ttf, .otf, .ttc)
Cross-platform build script (Nuitka & PyInstaller) + Inno Setup installer
Arch User Repository (AUR) packaging
Self-documenting user AppData session persistence
QR code generation and certificate verification credentials
Auto-update notifier and updater
macOS installer bundle (.dmg)
Android companion app

Acknowledgements & Dependencies

  • PyMuPDF – Ultra-fast PDF rendering and document manipulation
  • PySide6 / Qt – Modern cross-platform graphical user interface
  • pandas & openpyxl – Robust spreadsheet and CSV ingestion

License

Distributed under the Apache License 2.0. See the LICENSE file for details.