Skip to content

Releases

v0.3.3

Choose a tag to compare

@Frooodle Frooodle released this 03 Nov 10:42
68bd2ad

Stirling Office Convert 0.3.3 fixes attachment and metadata preservation when converting PDF to PDF/A.

PDF/A preservation

  • Keep eligible attachments referenced only by associated-file arrays or annotations, including when their original annotation is removed.
  • Normalize legacy DOS, Mac and Unix embedded-file references without losing payload bytes. Preserve distinct file variants and duplicate filenames.
  • Retain valid predefined XMP properties on pages, images and fonts instead of discarding the entire metadata packet.
  • Verify attached PDFs against their actual PDF/A conformance for PDF/A-2 and PDF/A-4 output, rather than trusting their declarations.
  • Fail safely when a retained attachment cannot be decoded or verified within the resource limits. The file-based API leaves an existing output unchanged instead of returning an empty or missing payload.
  • Reject oversized non-PDF attachment variants before applying the PDF verification limit; retain safe refusal for oversized genuine PDFs.

The selected profile's restrictions still apply: PDF/A-1 excludes attachments, PDF/A-2 and base PDF/A-4 require compatible PDF/A attachments, and PDF/A-3 supports arbitrary attachment formats. These fixes preserve data already embedded in the input PDF.

Packaged CLI

  • Keep the validator's required runtime classes in the distributed CLI JAR.
  • Add packaged-JAR tests to the standard check gate.

The attached CLI JAR requires Java 25 or later. SHA256SUMS.txt contains its checksum.

Verification

  • Linux and Windows CI, dependency licences, build, Javadocs and local Maven publication passed.
  • Added 65 PDF/A regression cases and three packaged-CLI cases.
  • A generated matrix of 176 cases with 46 payload samples across all nine supported profiles returned zero lost eligible payloads and zero veraPDF output failures.

Changes: #151

Full changelog: v0.3.2...v0.3.3

v0.3.2

Choose a tag to compare

@Frooodle Frooodle released this 02 Nov 12:05
c250266

Stirling Office Convert 0.3.2

PDF to Office

  • MathJax and KaTeX formulas (Obsidian, browser exports) are rebuilt from their layout: real sub- and superscripts in XLSX, ODS, ODT, HTML, Markdown and PPTX, and native Word equations in DOCX with fractions, roots, limits, nested scripts and cases
  • Formula tables keep overbars, hats and tildes on their letters (x̄, π̂, x̃), radicals read as √, and a repeated table header is not glued into the previous page's last row
  • Content in hidden layers is left out; damaged PDFs open in every feature; garbled pages no longer show junk text
  • Fonts drawn smaller than their own cap height are sized by what is drawn; .notdef codes and placeholder spaces no longer show as stray characters or hide word gaps
  • Highlights shade the words under them, barcodes keep their modules, CalRGB and clamped colours match viewers, small pages keep their size, column breaks land in the right column
  • One failed paint no longer drops the rest of a page
  • Output is deterministic: the same input gives byte-identical files

PDF/A

  • Passes the remaining veraPDF rules on almost all of the pdf.js corpus at every level, and all of pdfium's tests
  • u and a levels keep text as extractable as b
  • Unembedded CJK and CID fonts get stand-ins that cover their text, so pages no longer render blank
  • Transfer functions, soft masks, JPEG 2000 colour and CalGray are rendered correctly when flattening

Line art

  • As fast as 0.3.1 with identical output, and light yellow and orange fills stay solid

App

  • Every CLI output format is available in the web app, with the same option parsing, plus a sheet mode for XLSX and ODS
  • The app's page script loads again (it stopped on a syntax error, leaving the format picker empty)

Speed and safety

  • Script detection, glyph lookup, Arabic font matching, sheet lookups and PDF/A token counting are faster (HTML/EPUB to PDF about 15% less CPU, PDF to DOCX about 8%)
  • Formula, overline and radical work is capped for hostile input, and equation text drops characters that are not valid XML

API

  • Removed undocumented public members that nothing used: PdfTableExtractor, Units.* except emu(), ExtractedTable.toGrid, ExtractedCell.isMerged, CellStyle.withAlignment, PdfOutput.hasDestination, HtmlDocument.targetBookmark

v0.3.1

Choose a tag to compare

@Frooodle Frooodle released this 31 Oct 15:20
e573d50

Stirling Office Convert 0.3.1

PDF to Office text

  • Fonts without a Unicode map (bitmap Type 3 TeX fonts, CID fonts without ToUnicode) give readable text instead of junk or nothing
  • Unembedded TeX fonts (Computer Modern, AMS, Euler), Wingdings, Webdings, Symbol and core Word fonts are read through their own encodings; accents placed over letters join them ("Nordström", "naïve")
  • Upright and OCR text on rotated pages is kept, shadow copies are dropped, list-box values are kept
  • Right-to-left text extracts whole

Office to PDF

  • CFF and collection fonts (.otf, .ttc, .otc) are embedded, so CJK, symbol fonts and emoji stop drawing as boxes
  • Colour emoji in Word, PowerPoint and HTML; Excel draws them monochrome as Excel does; emoji sequences and flags take one width
  • XLSX closer to Excel: column widths from Excel's digit widths for 30 Office fonts, Arial row heights, bold headers, long words breaking, #### for numbers that do not fit, government workbooks' print areas
  • CJK fallback text and list numbers take Word's line height; stem and branch lists continue in decimal after 10 and 12
  • Page-bottom objects, headers and missing cloud fonts placed like Word; Lotus 1-2-3 number formats and column widths; CSV without a file-name header

HTML and eBooks

  • Email HTML laid out like Chrome: legacy align, page and body colour, margins, cell padding, sized blocks, link buttons, text-autospace
  • Rounded corners, shadows and gradients; Chrome's print margins
  • CLI folder mode converts eBooks and zips too

Safety and fixes

  • Overflowing XLSX cell text is drawn only where a page can show it, and emoji-dense sheets stay small
  • Bounds on CFF subsetting, Type 3 glyph reading, Lotus files and XLSX styles for untrusted input
  • Font files are no longer held open after loading (Windows)
  • Blank pages left out past the 10,000-page fill limit are reported

v0.3.0

Choose a tag to compare

@Frooodle Frooodle released this 30 Oct 14:25
0cc42d4

Stirling Office Convert 0.3.0

New conversions

  • PDF to PDF/A-4, plus PDF/A font, ToUnicode, colour-space and structure-tree fixes for parts 1–3
  • PDF to Markdown, HTML (fixed layout, with embedded web fonts), JSON, EPUB and Kindle AZW3
  • HTML, JSON, EPUB, MOBI, AZW3 and FB2 to PDF; HTML pages from ZIPs; HTML form controls become fillable PDF fields
  • Visio 2003–2010 drawings from their page preview; password-protected OpenDocument files
  • New modules: stirling-office-convert-optimize (bounded lossless PDF optimization and cross-reference repair) and stirling-office-convert-lineart (PDF line-art conversion with bilevel codecs)
  • Scanned-photo splitting into separate cropped pictures
  • PDF font conversion, missing-font embedding and Brotli stream support

Fidelity

  • HTML to PDF: flex, grid, floats, columns, absolute/fixed boxes, transforms, SVG text, gradients, RTL, widows/orphans, @page margin boxes and running headers
  • Office to PDF: charts closer to LibreOffice (ODF, legacy XLS, radar), list numbering, SmartArt text, ODS paper and row sizing, RTF footnotes, Word freeforms, legacy PPT gradients and shapes
  • PDF to Office: native slide gradients and lines, less common fonts embedded in ODT/DOCX, better justification, superscripts and running headers
  • PDF bookmarks from headings, slides and sheets
  • Smaller CLI jar (ProGuard) and faster legacy slide drawing, JPEG encoding and photo splitting

Safety and limits (for servers converting untrusted files)

  • One JVM-wide memory gate for every conversion, now configurable: memoryBudgetPercent, maxConcurrent, maxWaitSeconds (600) and refuseOversize, by system property or Admission.configure(...)
  • Admission.status() reports budget, memory in use, running, slots and stuck workers; new Admission.Busy and Admission.TooLarge refusals
  • Fixed a self-deadlock when a conversion took a nested memory ticket (PDF to EPUB covers)
  • Every page render has an operator, form, image, annotation and Type3 budget, checks for interrupts and turns stack overflows and out-of-memory into normal errors
  • Image memory is charged at what PDFBox really allocates; oversized images are drawn subsampled instead of dropped
  • Caps on DOCX body size, XML parts, slide shapes, path points, CSS rules and selector work; nested rotated table cells no longer take exponential time
  • PDF to Office now times out after 5 minutes by default; the CLI's --timeout covers every direction
  • Fixed regex denial-of-service in PDF/A metadata, page links and CMap parsing
  • Every limit is documented in docs/limits.md

Behaviour changes

  • OfficeConvert.Settings.defaults() has a 5-minute timeout (was none)
  • PDF/A flattening fails instead of writing a partial page when a page exceeds its render budget
  • Photo splitting refuses PDFs over 1,000 pages
  • Very long DOCX bodies and HTML with very heavy CSS are cut off with a warning
  • Admission.Busy and Admission.TooLarge extend InterruptedIOException; check for them before treating it as a cancellation
implementation("com.stirling:stirling-office-convert:0.3.0")
implementation("com.stirling:stirling-office-convert-topdf:0.3.0")
implementation("com.stirling:stirling-office-convert-pdfa:0.3.0")

v0.2.2

Choose a tag to compare

@Frooodle Frooodle released this 05 Oct 18:08
673aab8

Stirling Office Convert 0.2.2

PDF to Word fixes for web pages printed from browsers (#5):

  • Bold words drawn as outlines stay in the text flow instead of overlapping text
  • Inline code pills become bordered monospace text instead of floating boxes
  • Code blocks keep their light bordered box (were solid black)
  • Fewer extra pages (sample: 18 -> 14, matching the source)
implementation("com.stirling:stirling-office-convert:0.2.2")

v0.2.1

Choose a tag to compare

@Frooodle Frooodle released this 05 Oct 12:04
534086d

Stirling Office Convert 0.2.1

Fixes found comparing against LibreOffice on real documents (#4):

  • Fillable forms (IRS 1040, W-9) convert page for page with every label, box and checkbox in place
  • Two-column pages keep their columns and stay above the page number
  • Research paper title blocks align; compound line-end hyphens kept
  • PDF to PowerPoint keeps dark slide backgrounds; OCR text over scans is invisible but searchable
  • Spreadsheets no longer print hundreds of blank pages from merged cells or white fills
  • Legacy .doc table borders, freeform shapes and pagination; .xls text in pictures no longer overlaps
  • PDF/A: forms with empty-text fonts now pass veraPDF
implementation("com.stirling:stirling-office-convert:0.2.1")

v0.2.0

Choose a tag to compare

@Frooodle Frooodle released this 04 Oct 09:06
184eac4

Stirling Office Convert 0.2.0

  • Office to PDF conversion (DOCX, PPTX, XLSX) and PDF/A output (#3)
  • Completed Office conversion formats and safety fixes (#2)

Maven

implementation("com.stirling:stirling-office-convert:0.2.0")

The attached stirling-office-convert-cli-0.2.0.jar is the standalone command-line tool (java -jar).