RustPad Studio (rustpad) v3.0.13 is a native, sovereign, zero-dependency (0 external crates.io crates) desktop & CLI document intelligence engine written in 100% pure Rust. Built directly on native Win32 GDI + Windows 11 DWM & Linux X11 with a custom TrueType (.ttf) 4×4 supersampled rasterizer, 83+ classical multi-span inline math templates (Alt+= / /math), non-blocking LazyZipArchive 100+ MB .docx streaming parser, OOXML validator & corrupt-archive repair engine, character/paragraph redline & conflict-aware 3-way .docx smart merger, permanent .docx redactor plus modeled-content PDF redaction tools, and pure-Rust offline OCR — shipping as a ~4.1 MB standalone native executable (< 90 ms cold start, 0 Electron/Chromium/WebView bloat, no bundled AI agent, no telemetry).
Portfolio Case Study: nour-yahyaoui.vercel.app/projects/rustpad · Interactive Studio Showcase: rustpad-studio.vercel.app · Latest Release (
v3.0.13): GitHub Releases
| Platform | Architecture | Artifact |
|---|---|---|
| Windows 10 / 11 | x86_64 (Win32 GDI + DWM Dark Titlebar + Zero Console Window + Spooler) |
rustpad-v3.0.13-windows-x86_64.exe · rustpad.exe |
| Linux Desktop & CLI | x86_64 (dlopen X11 _GTK_THEME_VARIANT + CUPS/LP + Headless CLI) |
rustpad-v3.0.13-linux-x86_64 |
| SHA-256 Checksums | Cryptographic release manifest (windows + linux) |
SHA256SUMS.txt |
- 100% AI-Free Offline Core: Removed all AI agent modules (
ai_agent), HTTP/WinHTTP client bridges, the right-side AI Dock (Ctrl+J), floating selection"AI Polish", andrustpad aiCLI subcommands so RustPad operates without the bundled AI agent or its HTTP/WinHTTP integration. Core document editing is local/offline; operating-system services (for example printing) may still use system facilities. - Streamlined Studio Header & Home Launchpad: Replaced AI controls on the Home Hub with 1-click access to the Inline Math Library (
Alt+=/Ctrl+Shift+L) and tightened the contextual selection toolbar to pure typography & review controls (B,I,U,Highlight,Ink,+Note).
- Pure Win32 GUI Subsystem (
windows_subsystem = "windows"+CREATE_NO_WINDOW): Launchingrustpad.exeon Windows no longer opens or keeps a backgroundcmd.execonsole window open, while CLI subcommands (rustpad --version,rustpad convert, etc.) automatically attach to an existing PowerShell/cmdterminal viaAttachConsole(ATTACH_PARENT_PROCESS). - 83+ Inline Math Templates (
LinearAlgebra&ProbabilityExpansion): Added 24 ready-to-insert inline Linear Algebra and Probability/Statistics formulas (Dot Product, L1/L2/Frobenius Norms, Cosine Similarity,Ax = b, Matrix Product, Eigenvalues, SVD, QR/Cholesky, OLS, Orthogonal Projection, Cauchy–Schwarz, Kronecker/Hadamard, Bayes' Theorem, Conditional/Total Probability, Expectation, Variance, Correlation, Gaussian PDF, Z-Score/CI, Binomial/Poisson PMF, MLE, Chebyshev).
- Searchable Inline Math Template Picker (
Ctrl+Shift+L,Alt+=, Ribbon∑ Math,/math): Addeddoc_model::math_librarywith 50+ ready-to-insert inline mathematical building blocks, algebraic identities, trigonometric formulas, calculus derivatives/integrals/series, and Greek/domain symbols (∑,∏,∫,∮,√,∇,∂,ℝ,ℤ,ℕ,ℚ,ℂ,∀,∃,⇒,⇔) that insert as classical multi-spanTextSpans (SerifItalicvariables + real<w:vertAlign>superscript/subscriptbounds) fitting naturally inside prose line height with automatic clean-prose style continuation. - TrueType Math Symbol Fallback (
FontBook::face_for_char): Non-ASCII mathematical glyphs absent fromSeriforMonoslots automatically fall back toSansvector outlines with zero missing-glyph boxes.
- Adobe Standard-14 AFM PDF Metrics & Calibrated PDF Viewer: Replaced coarse average-glyph width approximations and
.trim()space stripping inpdf_create/pdf_engine/pdf_viewwith official per-codepoint Adobe AFM width tables (Helvetica,Helvetica-Bold,Times-Roman,Times-Bold,Courier) and calibratedSurface::draw_text_to_widthrendering — eliminating missing inter-span spaces, truncated underlines, and overlapping runs after bold/styled words. - 12-Slot TrueType Styling (
Bold+Italic+BoldItalic): ExpandedFontBook/FontSlotacross all(Sans | Serif | Mono) × (Regular | Bold | Italic | BoldItalic)combinations with 4×4 supersampled oblique italic shear and non-zero-winding span-dilated synthetic bold. - Word-Style Pending Typing Style & Lossless Span Editing: Toggling
Bold,Italic,Underline,Strikethrough,Superscript,Subscript, font family, font size, ink color, or highlight at a caret without a selection now queuespending_typing_stylefor newly typed text instead of overwriting existing paragraph runs;Enter,Backspace, andDeletepreserve all richTextSpanstyles across paragraph splits and merges; rich-span line wrapping, centering, and right-alignment measure per-span glyph advances with sub-pixel precision.
- Three Precision Studio Themes: Toggle effortlessly via the header Moon / Sun Theme Pill,
Ctrl+Shift+D, or Command Palette (Ctrl+K) across:Daylight(Warm Architectural Paper):#FAF8F3sheet on#ECE8E0linen desk with terracotta editorial accents.Midnight(Full Dark Studio):#1B1E24low-glare slate sheet on#121417obsidian desk with#E6E8EEcrisp chalk typography and#E07A5Fwarm accents.Hybrid Dark Desk:#121417dark studio chrome framing a#FAF8F3print-true warm paper sheet — zero glare around the margins while preserving 100% WYSIWYG print colors.
- Zero-Mutation Render-Time Ink Adaptation: Dark Mode never mutates underlying
DocumentorSpanStylecolors in saved.docx/.pdffiles. Near-black document ink, table borders, and light cell shading adapt purely at render time (StudioTheme::adapt_doc_ink), while explicit highlights and colored legal redlines remain high-contrast and print/PDF exports stay crisp white paper by default. - Native OS Integration & Persistence: Syncs Windows 11
DWMWA_USE_IMMERSIVE_DARK_MODEnative titlebars and Linux X11_GTK_THEME_VARIANT, auto-detects OS dark preference on first boot (Win32AppsUseLightTheme/GTK_THEME), and persists user choice in~/.rustpad/theme.conf.
- Zero-Copy Lossless OOXML Passthrough: Unparsed archive entries (
word/theme/*,customXml/*,docProps/*,word/embeddings/*, OLE packages, custom styles, unknown relationships) are carried via reference-countedSharedBytes(Arc<[u8]>) without heap duplication and written back byte-for-byte on save. - Structural
.docxValidator (rustpad validate): Verifies PKZIP Central Directory CRC32 integrity, mandatory[Content_Types].xml&_rels/.rels, XML tag nesting balance, relationship target resolution (word/_rels/document.xml.rels), and cross-linked footnote/endnote/comment IDs. - Corrupt / Truncated
.docxSalvage Engine (rustpad repair+ Auto-Recovery on Open): Scans rawPK\x03\x04local file headers when Central Directories are truncated or damaged, salvages intact XML/media streams, synthesizes missing OOXML scaffolding, and automatically recovers damaged.docxfiles on desktop open. - Formatting & Security Layer Inspector (
Ctrl+Shift+J/ Header Shield Icon /rustpad inspect --security --quality): Audits font/heading hierarchy drift,<w:vanish/>hidden text runs, near-white stealth text, externalTargetMode="External"hyperlinks/remote template injection,vbaProject.binmacros, embedded OLE objects, and author/company metadata.
- Rich Typography & Inline Semantics: Superscript (
<w:vertAlign w:val="superscript"/>), Subscript (subscript), clickable/preserved<w:hyperlink r:id="..."/>links,<w:vanish/>hidden spans, multi-span styling, and multi-column/shaded8×8interactive tables. - Section Breaks, First-Page Headers/Footers & Real Pagination: Explicit
Block::SectionBreak(NextPage,Continuous,EvenPage,OddPage),<w:titlePg/>(different_first_page) distinct cover headers/footers, and multi-page layout with cached glyph measurement. - First-Class Footnotes & Endnotes (
word/footnotes.xml&word/endnotes.xml): Insert footnotes and endnotes directly from the toolbar or Command Palette (AddFootnote/AddEndnote); renders superscript reference markers inline and numbered note dividers at page footers / document end in both Word Canvas and Vector PDF exports, with full ECMA-376 XML round-trip.
- Multi-Granularity Document Comparison (
rustpad compare): Produces structured reports covering paragraph-level edits, character-level inline diffs (--char-level), formatting attribute drift (bold,italic,font,size,color), table shape deltas, and header/footer/note changes. - 3-Way Smart
.docxMerge (rustpad merge Out.docx Base.docx Ours.docx Theirs.docx): Performs true conflict-aware 3-way.docxmerging (automatically fast-forwarding non-overlapping edits fromOursandTheirswhile isolating overlapping edits into explicit<<<<<<< OURS/=======/>>>>>>> THEIRSconflict blocks with ECMA-376 revision metadata), alongside 2-file concatenation.
- Permanent
.docxContent Redaction (rustpad redact): Physically scrubs custom terms and detected PII (emails, phones, SSNs, credit cards, IPv4 addresses) across body paragraphs, table cells, headers, footers, footnotes, endnotes, comments, and prior Track Changes history — replacing raw characters with█blocks so sensitive text never survives in XML. - One-Click Privacy & Metadata Cleaner (
CleanDocumentPrivacy/rustpad clean-meta): Strips author/company/revision metadata (docProps/core.xml,docProps/app.xml),customXml/*, comments,<w:vanish/>hidden spans, and tracked deletions in one atomic pass. - Forensic Secure Atomic Saves (
0600): Writes via permission-locked (0600on Unix) temporary sibling files withsync_all()disk flush before atomic rename so half-written or world-readable temp files never leak sensitive content.
- ** Crash-Safe Periodic WAL Autosave**: Automatically snapshots dirty documents every 45 seconds into SHA-256-verified Write-Ahead Log frames alongside multi-step Undo/Redo and local Version Snapshots (
Ctrl+Shift+S). - Multi-Surface Search, Duplicate Paragraph & Broken Link Detection: Searches across body, tables, headers/footers, footnotes, endnotes, and comments, and flags duplicate boilerplate clauses and broken internal
#anchor/ empty external hyperlinks inside the Document Inspector (Ctrl+Shift+J).
- Semantic HTML5 Export (
ExportWordToHtml/rustpad convert doc.docx doc.html): Exports clean semantic HTML5 with CSS@media (prefers-color-scheme: dark)support, footnotes/endnotes navigation, tables, redlines (<ins>/<del>), and inline base64 PNG figures. - 100% Pure-Rust Offline Bitmap OCR: Built-in zero-dependency connected-component + 8×12 topological feature-grid glyph recognizer (
pure_rust_bitmap_ocr_bytes) extracts ASCII text from uncompressed BMP/PNG/PGM scans completely offline, falling back cleanly to localtesseractonly when installed for complex camera scans. - Crash-Proof 100+ MB
.docxStreaming Foundation: RetainsLazyZipArchiveCentral Directory indexing, sub-sliceableSharedBytes, streaming<w:body>pull-parsing,32 MiBworker threads, and viewport block virtualization so massive.docxarchives open smoothly without blocking the UI thread.
Run rustpad --help on Windows, Linux, or macOS for headless CI/CD, legal ops, and CISO automation:
# 1. Validate OOXML Structure, Audit Security Layers & Salvage Corrupt .docx Archives
rustpad validate Contract.docx
rustpad inspect --security --quality Contract.docx
rustpad repair Truncated_Upload.docx -o Recovered.docx
# 2. Character-Level Legal Redlining, Structural Diff & 3-Way Smart .docx Merge
rustpad compare Base_v1.docx Counterparty_v2.docx
rustpad redline Base_v1.docx Counterparty_v2.docx -o Redline.docx --char-level --author "Legal Ops"
rustpad merge Merged.docx Base_v1.docx Counsel_A.docx Counsel_B.docx
# 3. Permanent .docx Redaction & Strict Metadata / Hidden-Text Privacy Cleaning
rustpad redact Deal.docx -o Deal_Redacted.docx --pii --term "Project Falcon"
rustpad clean-meta Deal_Redacted.docx -o Deal_Clean.docx
# 4. Modeled PDF text redaction, PDF/A-2b metadata & unkeyed SHA-256 integrity digest
rustpad sanitize Exhibit_A.pdf -o Exhibit_Clean.pdf
rustpad sign Exhibit_Clean.pdf -o Exhibit_Sealed.pdf --pdfa # Adds unkeyed content digest, not a digital signature
rustpad verify Exhibit_Sealed.pdf # Checks modeled-content digest only
# 5. Bidirectional Format Conversion (.docx / .pdf / .html / .md / .txt) & Batch Processing
rustpad convert Handbook.docx Handbook.html
rustpad convert Handbook.docx Handbook.pdf
rustpad batch pdf ./contracts_dir -o ./pdf_exports
# 6. Supply-Chain SBOM & MDM Air-Gapped Offline Policy
rustpad sbom -o rustpad-v3.0.13.cdx.json
rustpad policy --init-airgapped .rustpad-policy.json| Crate | Responsibility | External Deps |
|---|---|---|
crates/rustpad_zip |
LazyZipArchive (Zip64), corrupt ZIP header salvage, CRC32 verifier, bounded DEFLATE/Zlib, RFC 6234 SHA-256 |
0 |
crates/doc_model |
OpenXML AST (DocNote, SectionBreak, DocMetadata), char/paragraph compare & 3-way smart_merge_documents |
0 |
crates/docx_io |
Streaming <w:body> reader, lossless SharedBytes writer, footnotes/endnotes/hyperlinks, OOXML intelligence & repair |
0 |
crates/pdf_create |
ISO 32000 PDF 1.7 & PDF/A-2b vector generator, section breaks, footnotes/endnotes, hidden-span suppression, XMP | 0 |
crates/pdf_engine |
Limited PDF object/text parser, modeled text/annotation redaction, unkeyed SHA-256 /RustPadSeal integrity digest |
0 |
crates/power_tools |
.docx redactor & metadata cleaner, multi-surface search, batch ops, HTML5 converter, pure-Rust OCR, MDM DLP & SBOM |
0 |
crates/rustpad_render |
ThemeMode (Daylight/Midnight/HybridDarkDesk), StudioTheme, TrueType 4×4 rasterizer, SDF painter, PNG/JPEG/BMP |
0 |
crates/rustpad_window |
Native Win32 GDI + DWM Dark Titlebar & Linux X11 _GTK_THEME_VARIANT, HiDPI, clipboard, file dialogs & print spooler |
0 |
app (rustpad) |
Unified 60–120Hz native desktop studio (98 studio commands) + 18-command headless CLI |
0 |
See the Security Review for priority-by-priority status and remaining validation work.
- Passive Macro & OLE Safety by Design: Embedded
vbaProject.binmacros and OLE packages are preserved losslessly on save (or stripped on demand viaCleanDocumentPrivacy/clean-meta) and never executed, eliminating macro malware execution vectors. - Offline OCR Scope: The built-in pure-Rust bitmap OCR engine recognizes clean high-contrast Latin/ASCII printed bitmaps (
BMP/PNG/PGM) with zero external dependencies; skewed multi-language camera scans automatically delegate to a local offlinetesseractbinary when installed. - PDF digest is not a digital signature:
/RustPadSealstores an unkeyed SHA-256 digest of the parser's modeled page geometry, text, and vector rectangles. It can detect changes against a trusted copy, but it does not authenticate the named signer, and an attacker who can rewrite the file can recompute the digest. Use a standards-based certificate-backed PDF digital signature when identity, non-repudiation, or legal signature validation is required. - PDF redaction boundary:
sanitize_redactionsremoves intersecting modeled text runs and overlapping modeled annotations. This parser does not model arbitrary image content, form XObjects, or every PDF layer/filter. Do not rely on this feature alone to sanitize arbitrary third-party PDFs for sensitive disclosure; independently inspect/validate the output with a full-featured forensic PDF tool. - RTL / Arabic boundary: RTL detection and right alignment exist, but full Unicode Bidirectional Algorithm handling, Arabic contextual shaping, and complete Arabic glyph coverage are not guaranteed by the bundled renderer. Review Arabic output in the target application before publication.
Requires only the standard Rust toolchain (rustc / cargo, zero external system libraries on Windows; libX11 on Linux desktop):
cargo test --workspace
cargo build --release -p rustpadWindows Authenticode code signing for rustpad-studio / rustpad is managed via SignPath.io (certificate by SignPath Foundation).
- Committers, Reviewers & Approvers: Nour Yahyaoui (
@Nour-yahyaoui) - Reproducible CI Pipeline: Release artifacts are built exclusively from public source commits via GitHub Actions (
.github/workflows/release.yml) with0third-partycrates.ioruntime dependencies. Local/HSM Authenticode signing is also supported viascripts/sign-windows.ps1. - Privacy Policy: The v3.0.13 application source removes the bundled AI agent and its HTTP/WinHTTP bridges. Core document editing is local; this statement does not imply that operating-system services such as printing are network-free.
Built and architected from scratch in pure Rust by Nour Yahyaoui (Tunis, Tunisia):
- GitHub: @Nour-yahyaoui · Repository: Nour-yahyaoui/rustpad
- LinkedIn: linkedin.com/in/nour-yahyaoui-86987b36b
- Portfolio: nour-yahyaoui.vercel.app
- Email: nourryahyaoui@gmail.com
Licensed under the MIT License.
