Repository navigation
docs(docx): say in the capability matrix what the DOCX export carries - #913
Merged
Merged
Conversation
The matrix's DOCX column said the export ignores the layout's geometry, carries no font, writes no external link and no reproducible bytes, and that an anchor on a shape or a barcode marks nothing. The export reads the layout, when it has one, for how tall a line is, how wide a column came out and where a drawing stands. It ships the faces its styles name in Word's font table, and names a face whose licence keeps it out or that cannot be read. It writes the link of a paragraph, a run, a picture in a line and a page zone's picture as a w:hyperlink, and names the link on a block it holds as a picture, a drawing, a rule or a table, which is why both link rows are now marked degraded. It pins its clocks under deterministic(true). It bookmarks a barcode's anchor and a rule's, and names the anchor of a drawing floated over the text, of a stack's layer written as a column and of a page zone's paragraph or picture.
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.
Why
The DOCX column of
docs/architecture/backend-capability-matrix.mddescribed an export thisrepository no longer has. It said the backend "deliberately ignores fixed-layout geometry",
marked font portability ❌ ("nothing is carried"), external hyperlinks ❌ and deterministic
output ❌, and said "an anchor on a node the export drops (a shape, a barcode) has nothing to
mark". The code says otherwise for each, so a reader choosing a backend from the matrix was told
the DOCX export cannot do what it does.
What changed
resolved layout, when it has one, for how tall a line is, how wide a column came out and
where a drawing stands (
applyLineHeight,DocxLayoutMetrics.tableColumns, the drawings'own fragments), linking the recipe's "Measured geometry".
DocxFontTable+DocxFontEmbedding: a bundled or registered familythe body, a page zone or a header band names is carried in Word's font table, only the faces
its styles name, each obfuscated against a key derived from the font; whole faces, no
subsetting. A face whose
OS/2fsTypeforbids embedding or allows reading and printingonly, and one that cannot be read, is named but not shipped (
embedded font). Standard-14names carry no binary.
DocxSemanticBackend.newRun: a paragraph's, a run's, apicture-in-a-line's and a page zone picture's link is a
w:hyperlinkwith an externalrelationship, a run's own link winning over its paragraph's. A block written as a picture, a
drawing or a rule, and a table, carry none, and the report names the link — the deviation the
and a rule's anchor are bookmarked (
blockAnchorOf); a drawing floated over the text, astack's layer written as a column and a page zone's paragraph or picture hold no bookmark, and
the report names the anchor; a page reference to one is the number the layout found.
DocxDeterminism, throughDocxSemanticBackend.builder() .deterministic(true)ordeterministic(Instant); an embedded font's obfuscation key isderived from the font, so it needs no pinning.
CHANGELOG.md, v2.5.0 Documentation: one entry.Verification
file:lineevidence (newRun and its callers,
carriedWithout, the rule and barcode notes,blockAnchorOf,DocxFontTable.resolve/addFace,DocxFontEmbedding.permissionOf,DocxDeterminism, the builder).EnginePdfBoundaryTest,DocumentationCoverageTestand the rest of CI's list,
-pl :graph-compose-core) — BUILD SUCCESS, 83 tests.check-claims --check,check-routes,check-stability-docpass.Lane: docs — the capability matrix and the changelog; no code change.