fix(odf): put a page-anchored frame on the page, and lay a document out on the master page it names - #690
Merged
Merged
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 5a0e00d1a3
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
andiwand
force-pushed
the
fix/pdf-text-baseline-cmyk-jpx
branch
from
August 14, 2026 18:43
2aac9d2 to
fab329c
Compare
andiwand
force-pushed
the
fix/odf-page-anchored-frames
branch
from
August 14, 2026 18:44
5a0e00d to
6d6a58f
Compare
andiwand
force-pushed
the
fix/odf-page-anchored-frames
branch
from
August 14, 2026 18:50
6d6a58f to
522c4cc
Compare
A frame took its placement from its wrap alone, so one anchored to the page floated into the running text: a letter's address, date and footer boxes landed between the paragraphs instead of in their fields. Only a frame anchored in the text reads the wrap now; one anchored to the page sits at its own coordinates on it. The reference output also picks up the shipped css and js, which had drifted from what the engine emits since #679, #682, #683 and #685 - the same html rendered differently there than freshly generated. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01J8PCMZUVxuGstmmgQzEdif
A text document took the first master page in the file. A paragraph may name the one its page uses (20.283), which is how a letter template asks for the margins that leave room for its letterhead - 9.85cm at the top of the DIN 5008 template, where the address boxes sit. One page box is all this renders, so only a name that still precedes every written word counts; taking a later one put a whole document on the landscape page a single section had asked for. Frames are passed over on the way: they are anchored, not written. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01J8PCMZUVxuGstmmgQzEdif
andiwand
force-pushed
the
fix/odf-page-anchored-frames
branch
from
August 14, 2026 18:53
522c4cc to
968c0d1
Compare
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.
🤖 Generated with Claude Code
Stacked on #689. Both found on
Din_5008_business_letter.ott, the letter template #688 adds, compared against LibreOffice's render of the same file.A frame took its placement from its text wrap alone. Only
as-charwas special-cased; everything else went to a float or a margin box. All five frames in that template aretext:anchor-type="page"withsvg:x/svg:y, so the address block, the contact block, the date and the footer floated into the running text and the body wrapped around them in a narrow column. A frame anchored to the page now sits at its own coordinates on the page box; only a frame anchored in the text reads the wrap. Text does not flow around a page-anchored frame — css cannot both place a box away from where it sits in the flow and let the flow react to it, and the frame's place in the flow is not where it lands on the page.A text document took the first master page in the file. A paragraph may name the one its page uses (ODF 20.283), which is how that template asks for the 9.85cm top margin that leaves room for its letterhead — without it the body started at 2cm and ran under the address boxes. One page box is all this renders, so only a name that still precedes every written word counts: taking the first one named anywhere put
mixed-layout.odt(portrait) andstyle+svm-various-2.odt(landscape) onto the page a single later section had asked for, both of which now keep the orientation LibreOffice opens them at. Frames are passed over on the way — they are anchored, not written.Three documents change: the template above, and
ruski.odtandefficiency+style-big+various-1.odt, which each name aFirst Pagemaster of their own and now get its margins.Also: the reference output's shipped css and js are refreshed. They had drifted from what the engine emits (
document.cssstill carried*{margin:0;position:relative}from before #685;text.csswas 394 bytes against 1317 today, from #679/#682/#683). Since every page links../../resources/, the same html rendered differently in the reference tree than freshly generated — confusing to look at, and it makes CI's screenshot compare compare two stylesheets as much as two renders. The drift was deliberately left alone in an earlier pass; this refreshes it.