From 1834c8886b15aa3b868e988c185ac5c344392886 Mon Sep 17 00:00:00 2001 From: Paul Buetow Date: Thu, 23 Apr 2026 09:06:37 +0300 Subject: Add ISO A4 PDF print/book pipeline, page-frame prompts, and usage docs Print and book PDF modes now letterbox each raster to A4 portrait at pdf.density; print uses the matte color for pads. CLI forces 3:4 generation for print|book unless --aspect-ratio is set. Cover, gallery, and back prompts gain DINA4PDF instructions when those modes are active. Introduce DescribePageFrame and PDF helpers with tests; add CLI tests for presentation and aspect precedence. Expand README and config example with A4 examples, language env vars, and page-format vs PDF behavior. Add sample Sumer vocabulary files. Made-with: Cursor --- internal/comic/pageframe_test.go | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 internal/comic/pageframe_test.go (limited to 'internal/comic/pageframe_test.go') diff --git a/internal/comic/pageframe_test.go b/internal/comic/pageframe_test.go new file mode 100644 index 0000000..c9c7c26 --- /dev/null +++ b/internal/comic/pageframe_test.go @@ -0,0 +1,22 @@ +package comic + +import "testing" + +func TestDescribePageFrame(t *testing.T) { + tests := []struct { + ratio string + want string + }{ + {"16:9", "landscape 16:9 format (widescreen)"}, + {"2:3", "portrait 2:3 format (tall comic book page proportions)"}, + {"3:2", "landscape 3:2 format (widescreen)"}, + {"1:1", "square 1:1 format"}, + {"", "landscape 16:9 format (widescreen)"}, + {"bogus", "bogus format"}, + } + for _, tt := range tests { + if got := DescribePageFrame(tt.ratio); got != tt.want { + t.Fatalf("DescribePageFrame(%q) = %q, want %q", tt.ratio, got, tt.want) + } + } +} -- cgit v1.2.3