Skip to content

v0.3.0 — Multi-page templates, text styles & graceful CLI errors

Latest

Choose a tag to compare

@connorferster connorferster released this 14 Aug 03:38
· 2 commits to main since this release
3fab850

Highlights

Since v0.2.0, ymprint gains multi-page layouts, richer text control, saner list syntax, and a CLI that no longer crashes on authoring mistakes.

New features

  • Multiple named page templates (#9) — define several page templates (e.g. first, body) with their own margins and backgrounds, and switch between them mid-document with _pagebreak / _nextpagetemplate.
  • Scoped, switchable text styles (#7) — swap named text styles within a frame via _textstyle, plus per-style align and underline attributes.
  • Explicit list syntax (#6) — _ul / _ol blocks for unordered/ordered lists; bare YAML lists now render as sequential paragraphs (fixing the overloaded-list ambiguity).
  • Background paths relative to source or config (#5) — control how background PDF paths are resolved.

CLI: graceful error handling (#10)

  • YAML syntax errors and _py block exceptions are caught and shown as compact, actionable panels that make clear the problem is in your document, not an ymprint bug.
  • Python-block tracebacks are truncated to their top + bottom frames and mapped back to the author's block source, highlighting the exact failing line.
  • SyntaxErrors get special handling, including a hint for the common source: vs source: | block-scalar mistake.
  • live mode is redesigned as a two-part panel (watch list + throbber over a status area) with a state-coloured border; a failed reload shows the error in place instead of killing the session.

Packaging

  • Build backend switched to flit with dynamic version/description.

Full changelog: v0.2.0...v0.3.0