😫 The Pain Point
You’re sharing a confidential draft with clients but need to mark it “CONFIDENTIAL” on every page. Doing this manually in Adobe Acrobat takes forever.
🚀 Agentic Solution
An Automatic PDF Watermarker that stamps every page with text or your logo.
Key Features:
- Text Watermarks: Diagonal “DRAFT” or “CONFIDENTIAL” stamps.
- Image Watermarks: Your company logo with opacity control.
- Position Control: Center, corners, or custom coordinates.
⚔️ Phase 1: Commander (Quick Fix)
For quick watermarking.
Prompt:
“I have a PDF
report.pdf. Write a Python script using pypdf and reportlab to:
- Text Watermark: Add ‘CONFIDENTIAL’ diagonally across each page.
- Style: Gray color, 50% opacity, large font.
- Output: Save as
report_watermarked.pdf.Print progress. Handle encrypted PDFs (skip with warning).”
Result: Protected documents ready for distribution.
🏗️ Phase 2: Architect (Permanent Tool)
For Legal/Compliance Teams.
Engineering Prompt:
**Role:** Python GUI Developer (PyQt6 Specialist)
**Task:** Create "PDF Watermark Pro" Desktop App
**Objective:** A batch stamping tool to apply text or image watermarks securely.
**Tech Stack:**
* Language: Python 3.10+
* GUI Library: PyQt6 (Cross-platform)
* PDF Engine: PyPDF2, reportlab
* Packaging: PyInstaller
**Functional Requirements:**
1. **UI Layout (PyQt6):**
* **Input:** Source PDF/Folder.
* **Mode:** Tabs for "Text Watermark" vs "Image Watermark".
* **Text Ctrl:** Input field, Font, Size, Color, Rotation (0-360).
* **Image Ctrl:** File Picker, Scale Slider, Opacity Slider.
* **Position:** 3x3 Grid (Top-Left...Bottom-Right) or Center.
2. **Core Logic:**
* Generate watermark PDF page using `reportlab`.
* Merge watermark layer onto every page of source docs.
* **Threading:** Processing loop runs in background.
3. **Deliverables:**
* `main.py`: Complete source code.
* `requirements.txt`: Dependencies.
* **Build Instructions:**
* Windows: `pyinstaller --onefile --noconsole main.py`
* macOS: `pyinstaller --windowed --noconsole main.py`
🧠 Prompt Decoding
- reportlab: Creates the watermark as a PDF layer. pypdf merges it onto each page.
🛠️ Instructions
- Install:
pip install pypdf reportlab - Copy Prompt → Run.