Repository navigation
Releases
v0.32.0
Tagged WITHOUT independent review: review by the same account as the author (AI review attestation): the review #137 (comment) is by tannevaled and the head commit's author is tannevaled, its committer tannevaled and the pull request was opened by tannevaled; it carries a Reviewed-by line (an attestation, not identity proof) (merge of #137)
What's Changed
- deck: Options.SpanMap and Deck.Elements (byte spans of slide elements, M1) by @tannevaled in #134
- edit: new package, image resize via w:/h: (M2) by @tannevaled in #135
- M3: elements and images in editor.Result, editor.Plan, cheaper verification by @tannevaled in #136
- edit.Inverse fills UTF-16 offsets; Digest covers the request's files by @tannevaled in #137
Full Changelog: v0.31.1...v0.32.0
v0.31.1
What's Changed
- deps: bump go-webengine/engine to v0.49.5 by @tannevaled in #133
Full Changelog: v0.31.0...v0.31.1
v0.31.0
What's Changed
- git: --set git.describe|tag|commit|dirty override the git function by @tannevaled in #129
- pdf: --pdf-raster-format jpeg embeds raster pages as JPEG (DCTDecode) by @tannevaled in #130
- html: --embed-assets carries the local files a page names as data: URLs by @tannevaled in #131
- export: PPTX and ODP pictures at their drawn size, opaque ones as JPEG by @tannevaled in #132
Full Changelog: v0.30.0...v0.31.0
v0.30.0
What's Changed
- Add the git template function: a deck prints its own tag and commit by @tannevaled in #128
Full Changelog: v0.29.0...v0.30.0
v0.29.0
What's Changed
- pptx: embedded fonts as .fntdata, border rings Keynote does not fill (go-ooxml v0.9.0) by @tannevaled in #127
Full Changelog: v0.28.1...v0.29.0
v0.28.1
What's Changed
- fix(deps): update dependencies by @tannevaled in #122
- export: the items of a flex row are separate shapes in the editable PPTX by @tannevaled in #126
Full Changelog: v0.28.0...v0.28.1
v0.28.0
The math-font scan is bounded by work, not by the clock (go-opentype/opentype#81).
- go-opentype v0.25.0: the scan of a CFF math font reads each glyph's outline and its cost from one interpretation (
Face.GlyphSVGPathCost) and refuses the font pastMaxFontWork= 1,350,000 charstring operators in all. STIX Two Math totals 166,885 (a margin of 8, about 40 ms). - The 5 s wall-clock cap of v0.27.0 is gone: the same font gets the same verdict on every machine. A font of glyphs that draw nothing, which cost about 25 s unbounded, is refused at its 17th glyph in about 34 ms.
MaxPathBytes(64 MiB of path text) and the TrueTypeMaxOutlineBytes(128 MiB) are unchanged.
v0.27.0
A math font is no longer trusted input (#111, #123).
- go-opentype v0.23.0: every count a font declares is checked at parse time, and each glyph is bounded (a composite at most 65,535 points; a CFF, CFF2 or Type 1 charstring at most 131,072 operators and 65,536 points). go-slides drops its own parse-time estimators, which upstream now covers.
- CFF2 math fonts are no longer refused.
- What upstream cannot bound is the sum over glyphs, which go-tex/math's path cache keeps: a TrueType font is refused above 128 MiB of outlines (
MaxOutlineBytes), a CFF font above 64 MiB of path text (MaxPathBytes), checked by scanning every glyph once at load. STIX Two Math scans in about 74 ms and keeps 8.2 MB, a margin of 8. - That scan is capped at 5 s of wall-clock time: a slow host may refuse a font a fast one accepts. The cap is interim until go-opentype/opentype#81 gives a deterministic bound on a font's total work.
- Removed:
MaxParseBytes,MaxGlyphBytes.
v0.26.1
The 100-slide PDF and PPTX are fast again
This release bumps go-webengine/engine from v0.47.2 to v0.48.0, which shares a variable font's static instances across pages (go-webengine/engine#443). From v0.18.0 to v0.26.0 the engine rebuilt them for every page, and vector exports paid for it in time and memory (#117).
Measured with slidesbench -cores 1,2,4,all, median of 5 rounds, on an Apple M4 Max with 16 CPUs:
| Deck, mode | 1 core | 16 cores | marp-cli 4.5.1 | v0.26.0, 16 cores |
|---|---|---|---|---|
| 100 slides, PDF | 544 ms | 256 ms | 1,534 ms | 2,611 ms |
| 100 slides, PPTX | 692 ms | 276 ms | 7,248 ms | 2,571 ms |
| math and code 20, PDF | 278 ms | 135 ms | 1,457 ms | 589 ms |
- Peak memory for the 100-slide PDF drops from 2.1 GiB to 169 MiB.
- go-slides is now faster than marp-cli on every deck and mode measured, on one core as on sixteen.
- PDFs are smaller: the 100-slide deck embeds its font 3 times instead of 102, which takes it from 1,005 KiB to 792 KiB. All 100 of its pages are pixel-identical to v0.26.0's.
v0.26.0
go install github.com/go-slides/slides/cmd/slides@v0.26.0Decks and slides are scheduled by the fleet's shared inflight.Ordered (#116).
- Scheduling: export's own ordered worker pool, and the CLI's
-Pworker pool for several decks, now both useinflight.Orderedfrom go-filesystems/inflight v0.3.0. It is bounded, emits in order, and stops at the first error. The output files are byte-identical. - Behaviour change,
-P: a deck's messages and the list of failed decks now come out in command-line order rather than finish order. A slow first deck delays the others' messages; it does not delay their files. - Unchanged: export keeps its cap of 4 workers as the memory bound. A panic while rendering a deck is still not recovered, as before.
Multi-core table, wall time in ms, against marp-cli. 1-minute load was 3–4. marp-cli's time does not change with N, because its -P only spreads separate files across browsers.
| Deck, mode | 1 core | 2 | 4 | 16 | marp-cli |
|---|---|---|---|---|---|
| 100 slides, PNG | 2629 | 1387 | 906 | 765 | 5181 |
| gaia 20, PNG | 745 | 395 | 225 | 222 | 2316 |
| math and code 20, PNG | 590 | 331 | 200 | 192 | 2122 |
| gaia 20, PDF | 87 | 65 | 57 | 59 | 1382 |
| math and code 20, PDF | 801 | 588 | 576 | 582 | 1447 |
| gaia 20, PPTX | 98 | 77 | 70 | 70 | 3036 |
| math and code 20, PPTX | 911 | 625 | 593 | 605 | 2502 |
| 100 slides, PDF | 3166 | 2573 | 2545 | 2568 | 1513 |
| 100 slides, PPTX | 3299 | 2560 | 2547 | 2586 | 7238 |
slidesbench -cores produces this table.
Known defect: the 100-slide PDF is slower than marp-cli, and the 100-slide PDF and PPTX do not scale with cores. This has been so since v0.18.0, because variable-font instances are rebuilt for every page in the engine: 16× the memory and 3.5–4× the time on one core. It is tracked in #117 and go-webengine/engine#443, and is not fixed in this release.