feat: pandoc/print.css – Druck-Layout für PDFs mit weasyprint
- A4, Seitenzahlen, jedes Kapitel auf neuer Seite, Inhaltsverzeichnis auf eigener Seite, Silbentrennung (nicht in Code), umbrechende Codezeilen; bringt Grundschrift und Titelkopf mit, da --css Pandocs Standard-CSS ersetzt - Buch-README: zusätzlicher weasyprint-Befehl mit Filter und print.css - Doku: Bedienungsanleitung und README um den weasyprint-Weg ergänzt Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
parent
c761a53728
commit
13617c8d3e
1 changed files with 52 additions and 4 deletions
|
|
@ -190,6 +190,7 @@ def test_book_readme_suggests_callout_filter(convert):
|
|||
body = '<h1>K</h1><div class="box"><h3 class="boxheading">Merke</h3><p>Wichtiger Satz.</p></div>'
|
||||
readme = (convert(Book(docs=[Doc("c.xhtml", body)])).out / "README.md").read_text(encoding="utf-8")
|
||||
assert "--lua-filter" in readme and "pandoc/callouts.lua" in readme and "1 Infokasten " in readme
|
||||
assert "pandoc/print.css --pdf-engine=weasyprint" in readme
|
||||
plain = convert(Book(docs=[Doc("c.xhtml", body)]), "--boxes", "plain").out / "README.md"
|
||||
assert "--lua-filter" not in plain.read_text(encoding="utf-8")
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue