Repository navigation
render-pipeline: twoside, twocolumn, page styles and marks (class-geometry steps 4-5) - #102
Closed
GoKubar wants to merge 1 commit into
Conversation
…steps 4-5)
Per-page left edges (even pages at \evensidemargin) via Laid::line_dx;
two-column pages from pairs of \textheight columns with \columnseprule;
\flushbottom glue set for two-sided/two-column documents and \sloppy in
two columns; header/footer lines from class-geometry StyleMacros (plain,
empty, headings, myheadings; body \pagestyle and \thispagestyle) with
\slshape running heads (Role::Slanted, ec-lmro metrics) and
\sectionmark/\chaptermark/\markboth/\markright marks; report/book
\chapter openers (\thispagestyle{plain}, \@makechapterhead, chapter.section
numbers); \noindent read from the source. Body-only input keeps
\pagestyle{empty}.
Oracle: tests/page_frame.rs, 22 pdflatex fixtures (positions read from
the PDF content streams by tools/page-frame-oracle/generate.py): chrome
83/83, rules 3/3, left edges 63/63, matched line starts 1970/1970 within
0.1pt. HW1/HW2 display lists and PDFs byte-identical.
Implementation-Agent: Claude Opus 5 (subagent kabir-claude class-geometry steps 4-5, mac-m5pro-kabir)
Commit-Executor: Claude Code direct Git
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
This was referenced Sep 13, 2026
Closed
Contributor
Author
GoKubar
deleted the branch
agent/kabir-claude/render-pipeline-class-geometry
September 13, 2026 18:12
GoKubar
deleted the
agent/kabir-claude/render-pipeline-class-geometry-2
branch
September 13, 2026 18:51
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Stacked on #99 (
agent/kabir-claude/render-pipeline-class-geometry@ 29aad13). This adopts class-geometry CONTRACT steps 4–5 incrates/render-pipeline. The page frame from class-geometry already carried every value needed.What changes in the layout
\evensidemargin. Blocks are still assembled at\oddsidemargin; each placed line gets an x offset (Laid::line_dx), applied inassemble. One-sided pages have offset 0.\textheight, and each pair becomes one page. The second column sits\columnwidth + \columnsepto the right. Columns are not balanced, as in LaTeX.\columnseprule(the class value or a preamble\setlength) is drawn centred in the gap, full column height, on every page.\parindent 1emand\sloppy.\flushbottomapplies to two-sided and two-column documents, as the standard classes do. A page that ends at an ordinary break has its glue stretched or shrunk to\textheight. Pages ended by\newpage/\clearpage, and the last page, keep natural glue.StyleMacros. The preamble\pagestylesets them; a body\pagestylechanges them from the page it ships on;\thispagestyleaffects one page.L\hfil C\hfil Racross\textwidth, at the header or footer baseline.\slshape, using a newRole::Slantedfont role (lmromanslant*withec-lmro*metrics).\ps@headingsdefines them. A chapter mark reads "CHAPTER 1.", then a space at space factor 3000, then a control space.\markbothand\markrightin the body set marks, and their argument text is removed from the body.\leftmarkis the last mark on the page.\rightmarkis the first mark on the page, or the previous page's last mark if the page has none.\chapterin report and book.\thispagestyle{plain}.\vspace*{50pt}, then "Chapter n" in\hugebold, 20pt of space, the title in\Hugebold, and 40pt of space.chapter.section.\noindentnow works. The compiler treats it as a no-op, so the adapter reads it from the source bytes; it applies when it comes directly before a paragraph.\pagestyle{empty}.Gates
01ca7847…, pdfcbca7ada…be332ddd…, pdfd74b0e9f…cargo test --release: 99 passed, 0 failed, 1 ignored (render-pipeline: page frame from class-geometry (CONTRACT steps 1-3) #99's 98 plus the newpage_frame).tests/latex_structure.rs's secnumdepth case now sets\pagestyle{empty}, because the plain footer prints "1".tests/page_frame.rschecks 22 fixtures infixtures/page-frame/. Expected positions are read from pdflatex's own content streams bytools/page-frame-oracle/generate.py(MacTeX 2026, pdfTeX 1.40.29, T1 with lmodern); pdftotext's xMin was cross-checked and agrees. Cargo tests never run TeX. Tolerance is 0.1pt everywhere.\columnseprule\noindentBefore this PR every chrome check was 0, two-column output ran to 5 pages instead of 3, and even-page edges were off.
Correction: the commit message of aaeb444 gives three totals wrong: chrome 83, left edges 63, line starts 1970. The table above has the correct figures, summed from the per-fixture output of
cargo test --release --test page_frame -- --nocapture. I did not amend, to avoid a force-push.Not implemented (documented in the README)
\cleardoublepageadds before anopenrightchapter that would start on an even page.\pagenumbering: numbering is always arabic from 1.\maketitle's\thispagestyle{plain}.\chapterin two-column documents (\@topnewpage).\inputfiles.🤖 Generated with Claude Code
https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu