diff --git a/api/classes/charts.ChartDataPatch.html b/api/classes/charts.ChartDataPatch.html
index d92ef9e62a..7d667069cb 100644
--- a/api/classes/charts.ChartDataPatch.html
+++ b/api/classes/charts.ChartDataPatch.html
@@ -45,7 +45,7 @@ placeholder in the document's text is left as it is.
diff --git a/api/classes/index.AbstractNumbering.html b/api/classes/index.AbstractNumbering.html
index 48b5b73624..a098045be7 100644
--- a/api/classes/index.AbstractNumbering.html
+++ b/api/classes/index.AbstractNumbering.html
@@ -35,7 +35,7 @@ Each abstract definition can contain up to 9 levels.
diff --git a/api/classes/index.Body.html b/api/classes/index.Body.html
index 66a3e7a392..f221683d91 100644
--- a/api/classes/index.Body.html
+++ b/api/classes/index.Body.html
@@ -37,7 +37,7 @@ section. The last section's properties are stored as a direct child of the body
diff --git a/api/classes/index.Bookmark.html b/api/classes/index.Bookmark.html
index 6aaf7fc0e1..eb93594e10 100644
--- a/api/classes/index.Bookmark.html
+++ b/api/classes/index.Bookmark.html
@@ -31,7 +31,7 @@ of a start marker, content, and an end marker.
diff --git a/api/classes/index.BookmarkEnd.html b/api/classes/index.BookmarkEnd.html
index 8d9dee0d34..4b7f28a9a4 100644
--- a/api/classes/index.BookmarkEnd.html
+++ b/api/classes/index.BookmarkEnd.html
@@ -35,7 +35,7 @@ taken from bookmarkUniqueNumericId (see BookmarkStart)
diff --git a/api/classes/index.BookmarkStart.html b/api/classes/index.BookmarkStart.html
index 5327ed9f06..da20622336 100644
--- a/api/classes/index.BookmarkStart.html
+++ b/api/classes/index.BookmarkStart.html
@@ -37,7 +37,7 @@ same as a Bookmark's.
diff --git a/api/classes/index.CellMerge.html b/api/classes/index.CellMerge.html
index 84ad742581..7886772d5a 100644
--- a/api/classes/index.CellMerge.html
+++ b/api/classes/index.CellMerge.html
@@ -31,7 +31,7 @@ the intermediate object format used by the xml serialization library.
diff --git a/api/classes/index.CellMergeAttributes.html b/api/classes/index.CellMergeAttributes.html
index 5d90c7bef4..b83efce12d 100644
--- a/api/classes/index.CellMergeAttributes.html
+++ b/api/classes/index.CellMergeAttributes.html
@@ -30,7 +30,7 @@ can define an xmlKeys map to specify the transformation.
diff --git a/api/classes/index.CheckBoxSymbolElement.html b/api/classes/index.CheckBoxSymbolElement.html
index 632998de4d..a7801d3c85 100644
--- a/api/classes/index.CheckBoxSymbolElement.html
+++ b/api/classes/index.CheckBoxSymbolElement.html
@@ -33,7 +33,7 @@ specifying the Unicode character and font to render.
diff --git a/api/classes/index.CheckBoxUtil.html b/api/classes/index.CheckBoxUtil.html
index 350287db0a..139594e2e3 100644
--- a/api/classes/index.CheckBoxUtil.html
+++ b/api/classes/index.CheckBoxUtil.html
@@ -33,7 +33,7 @@ including its checked state and the symbols used for checked and unchecked state
diff --git a/api/classes/index.CommentRangeEnd.html b/api/classes/index.CommentRangeEnd.html
index 2e3ad5e8d5..94a3695111 100644
--- a/api/classes/index.CommentRangeEnd.html
+++ b/api/classes/index.CommentRangeEnd.html
@@ -36,7 +36,7 @@ Must be paired with a CommentRangeStart with the same ID.
diff --git a/api/classes/index.CommentRangeStart.html b/api/classes/index.CommentRangeStart.html
index 0b5e2df394..dc4603bf20 100644
--- a/api/classes/index.CommentRangeStart.html
+++ b/api/classes/index.CommentRangeStart.html
@@ -36,7 +36,7 @@ Must be paired with a CommentRangeEnd with the same ID.
diff --git a/api/classes/index.CommentReference.html b/api/classes/index.CommentReference.html
index 94aca94ba6..d9d585d37d 100644
--- a/api/classes/index.CommentReference.html
+++ b/api/classes/index.CommentReference.html
@@ -36,7 +36,7 @@ It should be placed after the CommentRangeEnd element.
diff --git a/api/classes/index.Comments.html b/api/classes/index.Comments.html
index f332129ac5..2253394f8b 100644
--- a/api/classes/index.Comments.html
+++ b/api/classes/index.Comments.html
@@ -35,7 +35,7 @@ threading is activated and thread data is generated for commentsExtended.xml.
diff --git a/api/classes/index.CommentsIds.html b/api/classes/index.CommentsIds.html
index f9b572e0f6..f547f98e53 100644
--- a/api/classes/index.CommentsIds.html
+++ b/api/classes/index.CommentsIds.html
@@ -27,7 +27,7 @@ to a stable w16cid:durableId preserved by Word across edits.
diff --git a/api/classes/index.ConcreteHyperlink.html b/api/classes/index.ConcreteHyperlink.html
index 6d1d362eaf..a2f5fb752d 100644
--- a/api/classes/index.ConcreteHyperlink.html
+++ b/api/classes/index.ConcreteHyperlink.html
@@ -30,7 +30,7 @@ Use InternalHyperlink or ExternalHyperlink for creating hyperlinks in documents.
diff --git a/api/classes/index.DeletedTableCell.html b/api/classes/index.DeletedTableCell.html
index d221920bd3..84b3b26863 100644
--- a/api/classes/index.DeletedTableCell.html
+++ b/api/classes/index.DeletedTableCell.html
@@ -31,7 +31,7 @@ the intermediate object format used by the xml serialization library.
diff --git a/api/classes/index.DeletedTableRow.html b/api/classes/index.DeletedTableRow.html
index 230935673c..d3edc4b861 100644
--- a/api/classes/index.DeletedTableRow.html
+++ b/api/classes/index.DeletedTableRow.html
@@ -31,7 +31,7 @@ the intermediate object format used by the xml serialization library.
diff --git a/api/classes/index.DocumentDefaults.html b/api/classes/index.DocumentDefaults.html
index ff3c1fad9d..49a673cadd 100644
--- a/api/classes/index.DocumentDefaults.html
+++ b/api/classes/index.DocumentDefaults.html
@@ -34,7 +34,7 @@ paragraphs and runs in a document unless overridden by a style or direct formatt
diff --git a/api/classes/index.DrawingPatch.html b/api/classes/index.DrawingPatch.html
index 66a189201e..35d7d96d85 100644
--- a/api/classes/index.DrawingPatch.html
+++ b/api/classes/index.DrawingPatch.html
@@ -27,7 +27,7 @@ is one: it replaces the data of a chart made in Word.
diff --git a/api/classes/index.EndnoteIdReference.html b/api/classes/index.EndnoteIdReference.html
index c0fe5ad29a..e4053b6ee8 100644
--- a/api/classes/index.EndnoteIdReference.html
+++ b/api/classes/index.EndnoteIdReference.html
@@ -31,7 +31,7 @@ the intermediate object format used by the xml serialization library.
diff --git a/api/classes/index.EndnoteReferenceRunAttributes.html b/api/classes/index.EndnoteReferenceRunAttributes.html
index 1507736ad2..32d5d98a8a 100644
--- a/api/classes/index.EndnoteReferenceRunAttributes.html
+++ b/api/classes/index.EndnoteReferenceRunAttributes.html
@@ -30,7 +30,7 @@ can define an xmlKeys map to specify the transformation.
diff --git a/api/classes/index.Endnotes.html b/api/classes/index.Endnotes.html
index 43eb46b369..1e25801cae 100644
--- a/api/classes/index.Endnotes.html
+++ b/api/classes/index.Endnotes.html
@@ -31,7 +31,7 @@ the intermediate object format used by the xml serialization library.
diff --git a/api/classes/index.ExternalHyperlink.html b/api/classes/index.ExternalHyperlink.html
index 504e1e2a46..de582a1898 100644
--- a/api/classes/index.ExternalHyperlink.html
+++ b/api/classes/index.ExternalHyperlink.html
@@ -37,7 +37,7 @@ is converted to a ConcreteHyperlink with the relationship ID.
diff --git a/api/classes/index.FileChild.html b/api/classes/index.FileChild.html
index 0a2eee7fb2..2cf09d5b7d 100644
--- a/api/classes/index.FileChild.html
+++ b/api/classes/index.FileChild.html
@@ -28,7 +28,7 @@ to the document body. Examples include Paragraph and Table.
diff --git a/api/classes/index.FootNotes.html b/api/classes/index.FootNotes.html
index 06926af4f5..4df9866d64 100644
--- a/api/classes/index.FootNotes.html
+++ b/api/classes/index.FootNotes.html
@@ -36,7 +36,7 @@ line used when footnotes continue across pages.
diff --git a/api/classes/index.FooterWrapper.html b/api/classes/index.FooterWrapper.html
index 95e4c6d482..bca54cb1f6 100644
--- a/api/classes/index.FooterWrapper.html
+++ b/api/classes/index.FooterWrapper.html
@@ -29,7 +29,7 @@ Each section can have multiple footers for different page types.
diff --git a/api/classes/index.FootnoteReference.html b/api/classes/index.FootnoteReference.html
index f1687f509d..6d2739c7a7 100644
--- a/api/classes/index.FootnoteReference.html
+++ b/api/classes/index.FootnoteReference.html
@@ -27,7 +27,7 @@ and the footnote content by using a unique identifier.
diff --git a/api/classes/index.GridSpan.html b/api/classes/index.GridSpan.html
index 21b0020269..4a2cd477d5 100644
--- a/api/classes/index.GridSpan.html
+++ b/api/classes/index.GridSpan.html
@@ -34,7 +34,7 @@ in the table grid. This is used to merge cells horizontally (column span).
diff --git a/api/classes/index.HeaderWrapper.html b/api/classes/index.HeaderWrapper.html
index b27fbc262a..7de1de67a7 100644
--- a/api/classes/index.HeaderWrapper.html
+++ b/api/classes/index.HeaderWrapper.html
@@ -29,7 +29,7 @@ Each section can have multiple headers for different page types.
diff --git a/api/classes/index.HpsMeasureElement.html b/api/classes/index.HpsMeasureElement.html
index ac5349fa16..69c242c260 100644
--- a/api/classes/index.HpsMeasureElement.html
+++ b/api/classes/index.HpsMeasureElement.html
@@ -33,7 +33,7 @@ Values can be specified as numbers (interpreted as half-points) or with explicit
diff --git a/api/classes/index.IgnoreIfEmptyXmlComponent.html b/api/classes/index.IgnoreIfEmptyXmlComponent.html
index 1e91e01404..600764a9d3 100644
--- a/api/classes/index.IgnoreIfEmptyXmlComponent.html
+++ b/api/classes/index.IgnoreIfEmptyXmlComponent.html
@@ -39,7 +39,7 @@ to be excluded from the output.
diff --git a/api/classes/index.ImageRun.html b/api/classes/index.ImageRun.html
index 48a642cc05..161dda0774 100644
--- a/api/classes/index.ImageRun.html
+++ b/api/classes/index.ImageRun.html
@@ -33,7 +33,7 @@ including JPG, PNG, GIF, BMP, and SVG. Optionally wraps the run in
diff --git a/api/classes/index.ImportedXmlComponent.html b/api/classes/index.ImportedXmlComponent.html
index 92e552f300..e326e65ef1 100644
--- a/api/classes/index.ImportedXmlComponent.html
+++ b/api/classes/index.ImportedXmlComponent.html
@@ -30,7 +30,7 @@ templates or when you need to include pre-existing XML fragments.
diff --git a/api/classes/index.InitializableXmlComponent.html b/api/classes/index.InitializableXmlComponent.html
index a9d492070a..070938b5c5 100644
--- a/api/classes/index.InitializableXmlComponent.html
+++ b/api/classes/index.InitializableXmlComponent.html
@@ -30,7 +30,7 @@ create a new component that shares or extends the children of an existing compon
diff --git a/api/classes/index.InsertedTableCell.html b/api/classes/index.InsertedTableCell.html
index 67324b5340..c92abd4258 100644
--- a/api/classes/index.InsertedTableCell.html
+++ b/api/classes/index.InsertedTableCell.html
@@ -31,7 +31,7 @@ the intermediate object format used by the xml serialization library.
diff --git a/api/classes/index.InsertedTableRow.html b/api/classes/index.InsertedTableRow.html
index b01141e4f2..f3cfde300b 100644
--- a/api/classes/index.InsertedTableRow.html
+++ b/api/classes/index.InsertedTableRow.html
@@ -31,7 +31,7 @@ the intermediate object format used by the xml serialization library.
diff --git a/api/classes/index.InsertedTextRun.html b/api/classes/index.InsertedTextRun.html
index b7fbf748a2..88842154a2 100644
--- a/api/classes/index.InsertedTextRun.html
+++ b/api/classes/index.InsertedTextRun.html
@@ -37,7 +37,7 @@ made the insertion and when.
diff --git a/api/classes/index.InternalHyperlink.html b/api/classes/index.InternalHyperlink.html
index 006dd449fc..a828f96666 100644
--- a/api/classes/index.InternalHyperlink.html
+++ b/api/classes/index.InternalHyperlink.html
@@ -36,7 +36,7 @@ The bookmark must exist in the document for the hyperlink to function.
diff --git a/api/classes/index.LastRenderedPageBreak.html b/api/classes/index.LastRenderedPageBreak.html
index 4b1e009216..5217c500a7 100644
--- a/api/classes/index.LastRenderedPageBreak.html
+++ b/api/classes/index.LastRenderedPageBreak.html
@@ -23,7 +23,7 @@ This is typically generated by Word and not created manually.
diff --git a/api/classes/index.MathDegree.html b/api/classes/index.MathDegree.html
index 8a5d1561d4..3653661d77 100644
--- a/api/classes/index.MathDegree.html
+++ b/api/classes/index.MathDegree.html
@@ -28,7 +28,7 @@ For square roots, this element is typically hidden.
diff --git a/api/classes/index.MathFunctionName.html b/api/classes/index.MathFunctionName.html
index ca6e2bf1a2..95cff603d7 100644
--- a/api/classes/index.MathFunctionName.html
+++ b/api/classes/index.MathFunctionName.html
@@ -28,7 +28,7 @@ that appears before the function argument.
diff --git a/api/classes/index.MathFunctionProperties.html b/api/classes/index.MathFunctionProperties.html
index 135dd4aa7a..3d17e97941 100644
--- a/api/classes/index.MathFunctionProperties.html
+++ b/api/classes/index.MathFunctionProperties.html
@@ -28,7 +28,7 @@ such as function name alignment and spacing.
diff --git a/api/classes/index.MathLimitUpper.html b/api/classes/index.MathLimitUpper.html
index c78ac7bd7d..3392ee6191 100644
--- a/api/classes/index.MathLimitUpper.html
+++ b/api/classes/index.MathLimitUpper.html
@@ -36,7 +36,7 @@ commonly used for mathematical notation like lim with conditions above.
diff --git a/api/classes/index.MathPreSubSuperScript.html b/api/classes/index.MathPreSubSuperScript.html
index 97fd6b563b..3558445a7a 100644
--- a/api/classes/index.MathPreSubSuperScript.html
+++ b/api/classes/index.MathPreSubSuperScript.html
@@ -36,7 +36,7 @@ positioned before (to the left of) the base, commonly used in tensor notation.
diff --git a/api/classes/index.MathRadicalProperties.html b/api/classes/index.MathRadicalProperties.html
index 9787ef23ad..de9ebc8664 100644
--- a/api/classes/index.MathRadicalProperties.html
+++ b/api/classes/index.MathRadicalProperties.html
@@ -28,7 +28,7 @@ such as whether to hide the degree (for square roots).
diff --git a/api/classes/index.MathRun.html b/api/classes/index.MathRun.html
index 5e733b8468..054705974c 100644
--- a/api/classes/index.MathRun.html
+++ b/api/classes/index.MathRun.html
@@ -36,7 +36,7 @@ similar to how Run contains text in regular paragraphs.
diff --git a/api/classes/index.MathSubSuperScript.html b/api/classes/index.MathSubSuperScript.html
index ea8e0e7325..f5232954f1 100644
--- a/api/classes/index.MathSubSuperScript.html
+++ b/api/classes/index.MathSubSuperScript.html
@@ -36,7 +36,7 @@ commonly used for tensor notation or indexed variables with exponents.
diff --git a/api/classes/index.Media.html b/api/classes/index.Media.html
index f011e2f23d..c974662645 100644
--- a/api/classes/index.Media.html
+++ b/api/classes/index.Media.html
@@ -24,7 +24,7 @@ is stored with a unique key for retrieval.
diff --git a/api/classes/index.NextAttributeComponent.html b/api/classes/index.NextAttributeComponent.html
index 28a19afca7..c4d0e64022 100644
--- a/api/classes/index.NextAttributeComponent.html
+++ b/api/classes/index.NextAttributeComponent.html
@@ -34,7 +34,7 @@ This gives more control but is more verbose than XmlAttributeComponent.
diff --git a/api/classes/index.OnOffElement.html b/api/classes/index.OnOffElement.html
index f31e725ab3..21148edef5 100644
--- a/api/classes/index.OnOffElement.html
+++ b/api/classes/index.OnOffElement.html
@@ -34,7 +34,7 @@ it is explicitly disabled. When the value is true, the attribute is often omitte
diff --git a/api/classes/index.Packer.html b/api/classes/index.Packer.html
index 60f86c4169..814f6dc067 100644
--- a/api/classes/index.Packer.html
+++ b/api/classes/index.Packer.html
@@ -26,7 +26,7 @@ of the document structure into OOXML format and compression into a .docx ZIP arc
diff --git a/api/classes/index.PageBorders.html b/api/classes/index.PageBorders.html
index 45f6dae39d..4b1ef41cf5 100644
--- a/api/classes/index.PageBorders.html
+++ b/api/classes/index.PageBorders.html
@@ -34,7 +34,7 @@ including which pages display the borders and how they are positioned.
diff --git a/api/classes/index.PageTextDirection.html b/api/classes/index.PageTextDirection.html
index 859c5dbdea..bceb8a5f9c 100644
--- a/api/classes/index.PageTextDirection.html
+++ b/api/classes/index.PageTextDirection.html
@@ -30,7 +30,7 @@ for all pages in a section.
diff --git a/api/classes/index.Paragraph.html b/api/classes/index.Paragraph.html
index 94079d3701..336eafa705 100644
--- a/api/classes/index.Paragraph.html
+++ b/api/classes/index.Paragraph.html
@@ -36,7 +36,7 @@ various inline elements such as text runs, images, hyperlinks, and bookmarks.
diff --git a/api/classes/index.ParagraphPropertiesChange.html b/api/classes/index.ParagraphPropertiesChange.html
index 285e4abdf4..3441c39c40 100644
--- a/api/classes/index.ParagraphPropertiesChange.html
+++ b/api/classes/index.ParagraphPropertiesChange.html
@@ -31,7 +31,7 @@ the intermediate object format used by the xml serialization library.
diff --git a/api/classes/index.ParagraphPropertiesDefaults.html b/api/classes/index.ParagraphPropertiesDefaults.html
index f476e9cdb0..72f9266ddc 100644
--- a/api/classes/index.ParagraphPropertiesDefaults.html
+++ b/api/classes/index.ParagraphPropertiesDefaults.html
@@ -34,7 +34,7 @@ to all paragraphs in the document unless overridden.
diff --git a/api/classes/index.PositionalTab.html b/api/classes/index.PositionalTab.html
index 073ffffc57..b956eb0516 100644
--- a/api/classes/index.PositionalTab.html
+++ b/api/classes/index.PositionalTab.html
@@ -37,7 +37,7 @@ an exact alignment and position within the paragraph.
diff --git a/api/classes/index.RunPropertiesDefaults.html b/api/classes/index.RunPropertiesDefaults.html
index 8c47c9b08d..5b55981b71 100644
--- a/api/classes/index.RunPropertiesDefaults.html
+++ b/api/classes/index.RunPropertiesDefaults.html
@@ -34,7 +34,7 @@ to all text runs in the document unless overridden by styles or direct formattin
diff --git a/api/classes/index.SectionProperties.html b/api/classes/index.SectionProperties.html
index e1ed03994a..f2e2a3b038 100644
--- a/api/classes/index.SectionProperties.html
+++ b/api/classes/index.SectionProperties.html
@@ -35,7 +35,7 @@ A document can contain multiple sections with different properties.
diff --git a/api/classes/index.SectionPropertiesChange.html b/api/classes/index.SectionPropertiesChange.html
index d3731815a5..4e9c3582ca 100644
--- a/api/classes/index.SectionPropertiesChange.html
+++ b/api/classes/index.SectionPropertiesChange.html
@@ -31,7 +31,7 @@ the intermediate object format used by the xml serialization library.
diff --git a/api/classes/index.SimpleField.html b/api/classes/index.SimpleField.html
index 7a03a17aa5..d4da15900a 100644
--- a/api/classes/index.SimpleField.html
+++ b/api/classes/index.SimpleField.html
@@ -40,7 +40,7 @@ Simple fields are typically used for fields that don't require complex nesting.<
diff --git a/api/classes/index.SimpleMailMergeField.html b/api/classes/index.SimpleMailMergeField.html
index 2ab021e261..96d7f59b35 100644
--- a/api/classes/index.SimpleMailMergeField.html
+++ b/api/classes/index.SimpleMailMergeField.html
@@ -30,7 +30,7 @@ It creates a MERGEFIELD that will be populated with data during mail merge.
diff --git a/api/classes/index.StringContainer.html b/api/classes/index.StringContainer.html
index 93f44916c2..3f153eb6c6 100644
--- a/api/classes/index.StringContainer.html
+++ b/api/classes/index.StringContainer.html
@@ -30,7 +30,7 @@ rather than an attribute.
diff --git a/api/classes/index.StringEnumValueElement.html b/api/classes/index.StringEnumValueElement.html
index bf61f6546e..c8c61f2224 100644
--- a/api/classes/index.StringEnumValueElement.html
+++ b/api/classes/index.StringEnumValueElement.html
@@ -33,7 +33,7 @@ type parameter to enforce type safety for enum values.
diff --git a/api/classes/index.StyleForParagraph.html b/api/classes/index.StyleForParagraph.html
index 9d8d3df233..20445588b3 100644
--- a/api/classes/index.StyleForParagraph.html
+++ b/api/classes/index.StyleForParagraph.html
@@ -35,7 +35,7 @@ run-level properties (font, size, color) for text within the paragraph.
diff --git a/api/classes/index.StyleLevel.html b/api/classes/index.StyleLevel.html
index c2556f5408..1e9b583f11 100644
--- a/api/classes/index.StyleLevel.html
+++ b/api/classes/index.StyleLevel.html
@@ -20,7 +20,7 @@ custom styles to be included in the table of contents at specific levels.
diff --git a/api/classes/index.Styles.html b/api/classes/index.Styles.html
index eb6d789c38..056d1527ae 100644
--- a/api/classes/index.Styles.html
+++ b/api/classes/index.Styles.html
@@ -35,7 +35,7 @@ a way to define consistent formatting across a document.
diff --git a/api/classes/index.TDirection.html b/api/classes/index.TDirection.html
index 0d12122349..ed2c0b882b 100644
--- a/api/classes/index.TDirection.html
+++ b/api/classes/index.TDirection.html
@@ -34,7 +34,7 @@ useful for creating rotated text or supporting different writing systems.
diff --git a/api/classes/index.Table.html b/api/classes/index.Table.html
index 682a03f150..b66f35ae30 100644
--- a/api/classes/index.Table.html
+++ b/api/classes/index.Table.html
@@ -36,7 +36,7 @@ Tables are used to organize content into a grid structure.
diff --git a/api/classes/index.TableCellBorders.html b/api/classes/index.TableCellBorders.html
index 5e14a35712..869c059832 100644
--- a/api/classes/index.TableCellBorders.html
+++ b/api/classes/index.TableCellBorders.html
@@ -34,7 +34,7 @@ can be configured independently with different styles, colors, and widths.
diff --git a/api/classes/index.TableRow.html b/api/classes/index.TableRow.html
index ab65f4598e..044cbb1e24 100644
--- a/api/classes/index.TableRow.html
+++ b/api/classes/index.TableRow.html
@@ -36,7 +36,7 @@ one or more table cells that hold the actual content.
diff --git a/api/classes/index.TableRowProperties.html b/api/classes/index.TableRowProperties.html
index 3bd1d51cb2..8ccfe5ffc3 100644
--- a/api/classes/index.TableRowProperties.html
+++ b/api/classes/index.TableRowProperties.html
@@ -30,7 +30,7 @@ whether it can split across pages, and whether it's a header row.
diff --git a/api/classes/index.TableRowPropertiesChange.html b/api/classes/index.TableRowPropertiesChange.html
index e70fb18537..49c8b104b3 100644
--- a/api/classes/index.TableRowPropertiesChange.html
+++ b/api/classes/index.TableRowPropertiesChange.html
@@ -31,7 +31,7 @@ the intermediate object format used by the xml serialization library.
diff --git a/api/classes/index.VerticalMerge.html b/api/classes/index.VerticalMerge.html
index 3ec081400e..789e627b00 100644
--- a/api/classes/index.VerticalMerge.html
+++ b/api/classes/index.VerticalMerge.html
@@ -35,7 +35,7 @@ This is used to create row spans in tables.
diff --git a/api/classes/index.WpsShapeRun.html b/api/classes/index.WpsShapeRun.html
index 19182e480d..9838c571c0 100644
--- a/api/classes/index.WpsShapeRun.html
+++ b/api/classes/index.WpsShapeRun.html
@@ -28,7 +28,7 @@ options for fills, lines, effects and text layout, and can be any of the preset
diff --git a/api/classes/index.XmlAttributeComponent.html b/api/classes/index.XmlAttributeComponent.html
index ce23d3af8f..758a5bde1f 100644
--- a/api/classes/index.XmlAttributeComponent.html
+++ b/api/classes/index.XmlAttributeComponent.html
@@ -41,7 +41,7 @@ can define an xmlKeys map to specify the transformation.
diff --git a/api/classes/index.XmlComponent.html b/api/classes/index.XmlComponent.html
index cc088c47b1..9a5c3d4681 100644
--- a/api/classes/index.XmlComponent.html
+++ b/api/classes/index.XmlComponent.html
@@ -129,7 +129,7 @@ the intermediate object format used by the xml serialization library.
diff --git a/api/classes/math.MathBrackets.html b/api/classes/math.MathBrackets.html
index 2b953742a0..2ee084928e 100644
--- a/api/classes/math.MathBrackets.html
+++ b/api/classes/math.MathBrackets.html
@@ -29,7 +29,7 @@ with what they hold.
diff --git a/api/classes/math.MathLargeOperator.html b/api/classes/math.MathLargeOperator.html
index cfbc863fc6..059f859a9f 100644
--- a/api/classes/math.MathLargeOperator.html
+++ b/api/classes/math.MathLargeOperator.html
@@ -28,7 +28,7 @@ it applies to. MathSum and MathIntegral are two of the
diff --git a/api/classes/math.MathMatrix.html b/api/classes/math.MathMatrix.html
index 4267f99faa..7e982342d6 100644
--- a/api/classes/math.MathMatrix.html
+++ b/api/classes/math.MathMatrix.html
@@ -30,7 +30,7 @@ and Pages centre every column.
diff --git a/api/classes/math.MathPhantom.html b/api/classes/math.MathPhantom.html
index 6f811dd48a..b97cc516be 100644
--- a/api/classes/math.MathPhantom.html
+++ b/api/classes/math.MathPhantom.html
@@ -28,7 +28,7 @@ line things up with it. Or math that is seen but takes up no room, or less, as <
diff --git a/api/classes/shapes.ShapeCanvasRun.html b/api/classes/shapes.ShapeCanvasRun.html
index 96a18c0868..73b0447868 100644
--- a/api/classes/shapes.ShapeCanvasRun.html
+++ b/api/classes/shapes.ShapeCanvasRun.html
@@ -35,7 +35,7 @@ written in mc:AlternateContent, with the group as its fallback, unl
diff --git a/api/classes/shapes.ShapeGroupRun.html b/api/classes/shapes.ShapeGroupRun.html
index 1d0dfa453b..bfce380a0a 100644
--- a/api/classes/shapes.ShapeGroupRun.html
+++ b/api/classes/shapes.ShapeGroupRun.html
@@ -35,7 +35,7 @@ when shapes are moved on a
diff --git a/api/classes/shapes.ShapeRun.html b/api/classes/shapes.ShapeRun.html
index 98830f50f4..9d4a34eeb6 100644
--- a/api/classes/shapes.ShapeRun.html
+++ b/api/classes/shapes.ShapeRun.html
@@ -33,7 +33,7 @@ and arrowheads, and text inside it. It sits inline with text unless floati
diff --git a/api/classes/watermarks.ImageWatermark.html b/api/classes/watermarks.ImageWatermark.html
index c4746877df..97406f764e 100644
--- a/api/classes/watermarks.ImageWatermark.html
+++ b/api/classes/watermarks.ImageWatermark.html
@@ -46,7 +46,7 @@ way as an ImageRun.
diff --git a/api/classes/watermarks.TextWatermark.html b/api/classes/watermarks.TextWatermark.html
index 227147c168..f16587d599 100644
--- a/api/classes/watermarks.TextWatermark.html
+++ b/api/classes/watermarks.TextWatermark.html
@@ -44,7 +44,7 @@ recognizes it and can remove or replace it through that command.
\n option - causes the field result to be the paragraph number without trailing periods. No information about prior numbered levels is displayed unless it is included as part of the current level.
diff --git a/api/functions/index.convertToXmlComponent.html b/api/functions/index.convertToXmlComponent.html
index 102a652423..3bc7078788 100644
--- a/api/functions/index.convertToXmlComponent.html
+++ b/api/functions/index.convertToXmlComponent.html
@@ -36,7 +36,7 @@ of the original XML.
diff --git a/api/functions/index.createEmphasisMark.html b/api/functions/index.createEmphasisMark.html
index 79010e1f15..3e26e2a462 100644
--- a/api/functions/index.createEmphasisMark.html
+++ b/api/functions/index.createEmphasisMark.html
@@ -37,7 +37,7 @@ text to emphasize it. This is commonly used in East Asian typography.
diff --git a/api/functions/index.createFrameProperties.html b/api/functions/index.createFrameProperties.html
index 2a99202bfc..c1891bf4fc 100644
--- a/api/functions/index.createFrameProperties.html
+++ b/api/functions/index.createFrameProperties.html
@@ -41,7 +41,7 @@ drop cap effects and various text wrapping options.
diff --git a/api/functions/index.createHorizontalPosition.html b/api/functions/index.createHorizontalPosition.html
index 70ebceb191..9d64a3e373 100644
--- a/api/functions/index.createHorizontalPosition.html
+++ b/api/functions/index.createHorizontalPosition.html
@@ -40,7 +40,7 @@ object relative to a base element (page, margin, column, etc.).
diff --git a/api/functions/index.createMathAccentCharacter.html b/api/functions/index.createMathAccentCharacter.html
index 104f127085..ae5a01e64c 100644
--- a/api/functions/index.createMathAccentCharacter.html
+++ b/api/functions/index.createMathAccentCharacter.html
@@ -31,7 +31,7 @@ such as summation (∑), integral (∫), or product (∏) symbols.
diff --git a/api/functions/index.createMathNAryProperties.html b/api/functions/index.createMathNAryProperties.html
index cc4df63d78..ac38e752ba 100644
--- a/api/functions/index.createMathNAryProperties.html
+++ b/api/functions/index.createMathNAryProperties.html
@@ -31,7 +31,7 @@ and integrals, including the operator character and limit positioning.
diff --git a/api/functions/index.createMathSubScriptElement.html b/api/functions/index.createMathSubScriptElement.html
index 39df9af037..4d78a9f8f0 100644
--- a/api/functions/index.createMathSubScriptElement.html
+++ b/api/functions/index.createMathSubScriptElement.html
@@ -31,7 +31,7 @@ script objects, and other structures that support subscripts.
diff --git a/api/functions/index.createMathSuperScriptElement.html b/api/functions/index.createMathSuperScriptElement.html
index 22c9025250..bdd96616bd 100644
--- a/api/functions/index.createMathSuperScriptElement.html
+++ b/api/functions/index.createMathSuperScriptElement.html
@@ -31,7 +31,7 @@ script objects, and other structures that support superscripts.
diff --git a/api/functions/index.createPageNumberType.html b/api/functions/index.createPageNumberType.html
index 37d12aea95..9b236187e9 100644
--- a/api/functions/index.createPageNumberType.html
+++ b/api/functions/index.createPageNumberType.html
@@ -37,7 +37,7 @@ for all pages in a section.
diff --git a/api/functions/index.createSectionType.html b/api/functions/index.createSectionType.html
index 7c589cb73f..1e27ed8296 100644
--- a/api/functions/index.createSectionType.html
+++ b/api/functions/index.createSectionType.html
@@ -37,7 +37,7 @@ where the new section begins relative to the previous section.
diff --git a/api/functions/index.createTableFloatProperties.html b/api/functions/index.createTableFloatProperties.html
index 6ee463e198..21e49ae016 100644
--- a/api/functions/index.createTableFloatProperties.html
+++ b/api/functions/index.createTableFloatProperties.html
@@ -38,7 +38,7 @@ The overlap option isn't part of it: the table properties write it as w:tblOverl
diff --git a/api/functions/index.createTableLook.html b/api/functions/index.createTableLook.html
index 57cb4bf33a..584a8ec5f6 100644
--- a/api/functions/index.createTableLook.html
+++ b/api/functions/index.createTableLook.html
@@ -34,7 +34,7 @@ styles to apply special formatting to specific regions of the table.
diff --git a/api/functions/index.createTableRowHeight.html b/api/functions/index.createTableRowHeight.html
index 20d870d7f2..4036269abc 100644
--- a/api/functions/index.createTableRowHeight.html
+++ b/api/functions/index.createTableRowHeight.html
@@ -38,7 +38,7 @@ determining how the height should be applied.
diff --git a/api/functions/index.createWrapNone.html b/api/functions/index.createWrapNone.html
index 2506d43406..0aa316cc3c 100644
--- a/api/functions/index.createWrapNone.html
+++ b/api/functions/index.createWrapNone.html
@@ -23,7 +23,7 @@ without wrapping around it.
diff --git a/api/functions/index.createWrapSquare.html b/api/functions/index.createWrapSquare.html
index 489ee398e3..3d063ac9c1 100644
--- a/api/functions/index.createWrapSquare.html
+++ b/api/functions/index.createWrapSquare.html
@@ -32,7 +32,7 @@ of the drawing on the specified side(s).
diff --git a/api/functions/index.createWrapThrough.html b/api/functions/index.createWrapThrough.html
index 833b986832..d2e7d4bd24 100644
--- a/api/functions/index.createWrapThrough.html
+++ b/api/functions/index.createWrapThrough.html
@@ -36,7 +36,7 @@ fills any open space inside the drawing, such as the middle of a ring.
diff --git a/api/functions/index.createWrapTight.html b/api/functions/index.createWrapTight.html
index 80c30870b9..ffa5d28a5d 100644
--- a/api/functions/index.createWrapTight.html
+++ b/api/functions/index.createWrapTight.html
@@ -36,7 +36,7 @@ of the drawing rather than its rectangular bounding box.
diff --git a/api/functions/index.dateTimeValue.html b/api/functions/index.dateTimeValue.html
index 8a848fab5b..54e80166e9 100644
--- a/api/functions/index.dateTimeValue.html
+++ b/api/functions/index.dateTimeValue.html
@@ -36,7 +36,7 @@ This matches the xsd:dateTime format required by OOXML.
diff --git a/api/functions/index.fillPartPageNumbers.html b/api/functions/index.fillPartPageNumbers.html
index 8509ff1750..a2237ad4c9 100644
--- a/api/functions/index.fillPartPageNumbers.html
+++ b/api/functions/index.fillPartPageNumbers.html
@@ -35,7 +35,7 @@ are left as they are
diff --git a/api/functions/index.fillSequenceNumbers.html b/api/functions/index.fillSequenceNumbers.html
index 55799bb8a0..89542c7005 100644
--- a/api/functions/index.fillSequenceNumbers.html
+++ b/api/functions/index.fillSequenceNumbers.html
@@ -27,7 +27,7 @@ tables of contents are filled in from its headings, as Word leaves a heading's S
diff --git a/api/functions/index.hpsMeasureValue.html b/api/functions/index.hpsMeasureValue.html
index bb65a11452..5be13a7b38 100644
--- a/api/functions/index.hpsMeasureValue.html
+++ b/api/functions/index.hpsMeasureValue.html
@@ -36,7 +36,7 @@ HPS (half-points) are commonly used for font sizes.
diff --git a/api/functions/index.patchDocument.html b/api/functions/index.patchDocument.html
index 33fdf4f49d..34e074940c 100644
--- a/api/functions/index.patchDocument.html
+++ b/api/functions/index.patchDocument.html
@@ -42,7 +42,7 @@ the original document structure and optionally the original formatting.
diff --git a/api/functions/index.universalMeasureToTwips.html b/api/functions/index.universalMeasureToTwips.html
index ff9fbf8cbd..23c835659e 100644
--- a/api/functions/index.universalMeasureToTwips.html
+++ b/api/functions/index.universalMeasureToTwips.html
@@ -35,7 +35,7 @@ Strings are converted according to their unit suffix.
diff --git a/api/functions/layout.estimatePageNumbersWith.html b/api/functions/layout.estimatePageNumbersWith.html
index 942d7b0e63..9743a0d66f 100644
--- a/api/functions/layout.estimatePageNumbersWith.html
+++ b/api/functions/layout.estimatePageNumbersWith.html
@@ -32,7 +32,7 @@ options say. Give what it returns to a document as its pageNumbers,
diff --git a/api/functions/layout.layoutDocument.html b/api/functions/layout.layoutDocument.html
index c50cbfd2c2..578c257629 100644
--- a/api/functions/layout.layoutDocument.html
+++ b/api/functions/layout.layoutDocument.html
@@ -40,7 +40,7 @@ text box, it stops, and gives the pages up to there, with why in stoppedAt
diff --git a/api/functions/layout.measureWithPretext.html b/api/functions/layout.measureWithPretext.html
index ba2749b69d..c266bbcc5a 100644
--- a/api/functions/layout.measureWithPretext.html
+++ b/api/functions/layout.measureWithPretext.html
@@ -40,7 +40,7 @@ measures text in another, and Pretext keeps the widths it measured.
diff --git a/api/functions/math.latexToMath.html b/api/functions/math.latexToMath.html
index 9d1280af5d..45a845ee6c 100644
--- a/api/functions/math.latexToMath.html
+++ b/api/functions/math.latexToMath.html
@@ -44,7 +44,7 @@ cases and aligned equations, with \tag for their numbers. The math
diff --git a/api/interfaces/index.IXmlableObject.html b/api/interfaces/index.IXmlableObject.html
index 3ee1a4bbb0..277ce098e2 100644
--- a/api/interfaces/index.IXmlableObject.html
+++ b/api/interfaces/index.IXmlableObject.html
@@ -31,7 +31,7 @@ to generate the final XML output. Objects typically have a structure like:
diff --git a/api/types/charts.BarChartBaseOptions.html b/api/types/charts.BarChartBaseOptions.html
index a7e458d675..bd34bd35e4 100644
--- a/api/types/charts.BarChartBaseOptions.html
+++ b/api/types/charts.BarChartBaseOptions.html
@@ -31,7 +31,7 @@ Default is Office's: -27 for column charts and 0 for bar charts. Stacked bars al
@@ -49,14 +49,14 @@ bar, line or area chart spaces them by date
Sales. 2025: Jan 10, Feb 20.", and none for a decorative chart. An empty description removes it
+
diff --git a/api/types/charts.CategoryChartOptions.html b/api/types/charts.CategoryChartOptions.html
index 0f6c11fc63..ede2108743 100644
--- a/api/types/charts.CategoryChartOptions.html
+++ b/api/types/charts.CategoryChartOptions.html
@@ -59,7 +59,7 @@ in years, are labelled in rows, the groups below their categories
diff --git a/api/types/charts.ChartAxisCrossing.html b/api/types/charts.ChartAxisCrossing.html
index b05d2f5d93..e7b763a2ac 100644
--- a/api/types/charts.ChartAxisCrossing.html
+++ b/api/types/charts.ChartAxisCrossing.html
@@ -20,7 +20,7 @@ the value is the category's number, from 1, or when the categories are dates, a
diff --git a/api/types/charts.ChartAxisGroup.html b/api/types/charts.ChartAxisGroup.html
index 1d9cad7818..fd06d12b90 100644
--- a/api/types/charts.ChartAxisGroup.html
+++ b/api/types/charts.ChartAxisGroup.html
@@ -19,7 +19,7 @@ chart's are along the bottom and the top.
diff --git a/api/types/charts.ChartCategoryGroup.html b/api/types/charts.ChartCategoryGroup.html
index a78613ed84..7041ea705f 100644
--- a/api/types/charts.ChartCategoryGroup.html
+++ b/api/types/charts.ChartCategoryGroup.html
@@ -20,7 +20,7 @@ categories, or groups of its own, such as the months of each quarter of each yea
@@ -67,21 +67,21 @@ a point, and where they fit best on a pie. A chart's position is for the series
another way keep Office's, unless their own labels give one
diff --git a/api/types/charts.ChartDataPatchOptions.html b/api/types/charts.ChartDataPatchOptions.html
index 958f09feb5..4ab5777729 100644
--- a/api/types/charts.ChartDataPatchOptions.html
+++ b/api/types/charts.ChartDataPatchOptions.html
@@ -19,7 +19,7 @@ series' points, or for a stock chart its prices.
diff --git a/api/types/charts.ChartErrorBarsAmount.html b/api/types/charts.ChartErrorBarsAmount.html
index 0f0f836f87..6c85ae1cd7 100644
--- a/api/types/charts.ChartErrorBarsAmount.html
+++ b/api/types/charts.ChartErrorBarsAmount.html
@@ -64,7 +64,7 @@ deviations, or the standard error.
diff --git a/api/types/charts.ChartLineDash.html b/api/types/charts.ChartLineDash.html
index af14992f1e..47d4aaf02b 100644
--- a/api/types/charts.ChartLineDash.html
+++ b/api/types/charts.ChartLineDash.html
@@ -19,7 +19,7 @@ and so on.
diff --git a/api/types/charts.ChartPointLabel.html b/api/types/charts.ChartPointLabel.html
index 685cc193f1..ed4b35d1c0 100644
--- a/api/types/charts.ChartPointLabel.html
+++ b/api/types/charts.ChartPointLabel.html
@@ -19,7 +19,7 @@ format and its font. Anything left out is as the series' labels have it.
diff --git a/api/types/charts.ChartTrendline.html b/api/types/charts.ChartTrendline.html
index c8d18999b3..5b728e10f9 100644
--- a/api/types/charts.ChartTrendline.html
+++ b/api/types/charts.ChartTrendline.html
@@ -20,7 +20,7 @@ forecast. It is drawn as a dotted line in the series' colour, and has an entry i
@@ -57,7 +57,7 @@ forecast. It is drawn as a dotted line in the series' colour, and has an entry i
along the x axis. Default is 0. Not for moving averages
@@ -73,35 +73,35 @@ the x axis. Default is 0. Not for moving averages
linear, exponential and polynomial trendlines, and above 0 for exponential ones
+
diff --git a/api/types/charts.ChartValueAxis.html b/api/types/charts.ChartValueAxis.html
index 3d681b00f9..dc4b09394e 100644
--- a/api/types/charts.ChartValueAxis.html
+++ b/api/types/charts.ChartValueAxis.html
@@ -43,7 +43,7 @@ of 0 or less can't be shown. Default is a linear scale
diff --git a/api/types/charts.ComboChartSeriesType.html b/api/types/charts.ComboChartSeriesType.html
index 9050d9ef60..2a408c1a9a 100644
--- a/api/types/charts.ComboChartSeriesType.html
+++ b/api/types/charts.ComboChartSeriesType.html
@@ -19,7 +19,7 @@ or an area. A chart with series of more than one type is Word's "Combo"
@@ -59,14 +59,14 @@ with undefined, takes the next of the theme's accent colours
one for each slice in the order of the categories, where undefined leaves a slice in. Default is 0
+
diff --git a/api/types/charts.SplitPieChartBaseOptions.html b/api/types/charts.SplitPieChartBaseOptions.html
index a38c753254..2ee34aa368 100644
--- a/api/types/charts.SplitPieChartBaseOptions.html
+++ b/api/types/charts.SplitPieChartBaseOptions.html
@@ -42,7 +42,7 @@ second pie or a stacked bar, joined to the slice of the pie that stands for them
diff --git a/api/types/index.AttributePayload.html b/api/types/index.AttributePayload.html
index 2be5552150..07ad6c0f31 100644
--- a/api/types/index.AttributePayload.html
+++ b/api/types/index.AttributePayload.html
@@ -21,7 +21,7 @@ control over attribute name mapping.
Specifies the additional length, in EMUs, which shall be added to the bottom edge of the DrawingML object to determine its actual bottom edge including effects.
Specifies the additional length, in EMUs, which shall be added to the left edge of the DrawingML object to determine its actual left edge including effects.
Specifies the additional length, in EMUs, which shall be added to the right edge of the DrawingML object to determine its actual right edge including effects.
Specifies the additional length, in EMUs, which shall be added to the top edge of the DrawingML object to determine its actual top edge including effects.
@@ -63,14 +63,14 @@ name. The page references to a bookmark that isn't in it are left blank.
the first of them on may not be Word's. Nothing of them is written into the document.
+
@@ -88,7 +88,7 @@ those in headers, footers and notes.
in headers and footers only on its pages, show. Those of a section whose number is undefined are left blank.
+
diff --git a/api/types/index.GraphicMediaData.html b/api/types/index.GraphicMediaData.html
index 3ed746e75a..ccd6bc25ad 100644
--- a/api/types/index.GraphicMediaData.html
+++ b/api/types/index.GraphicMediaData.html
@@ -25,7 +25,7 @@ graphic it is. This is how docx/shapes writes its shapes.
diff --git a/api/types/index.IContext.html b/api/types/index.IContext.html
index 8aa4e9fb00..640126dc45 100644
--- a/api/types/index.IContext.html
+++ b/api/types/index.IContext.html
@@ -18,7 +18,7 @@ during the conversion of components to XML.
diff --git a/api/types/index.ICropOptions.html b/api/types/index.ICropOptions.html
index c9306f5d29..1b6ed979bd 100644
--- a/api/types/index.ICropOptions.html
+++ b/api/types/index.ICropOptions.html
@@ -19,7 +19,7 @@ side of the image.
The grid can define a grid which snaps all East Asian characters to grid positions, but leaves Latin text with its default spacing; a grid which adds the specified character pitch to each character on each row; or a grid which affects only the line pitch for the current section.
Specifies that the paragraph (or at least part of it) should be rendered on the same page as the next paragraph when possible. If multiple paragraphs are to be kept together but they exceed a page, then the set of paragraphs begin on a new page and page breaks are used thereafter as needed.
diff --git a/api/types/index.IRunOptions.html b/api/types/index.IRunOptions.html
index 38509b43f2..e2b7b0831c 100644
--- a/api/types/index.IRunOptions.html
+++ b/api/types/index.IRunOptions.html
@@ -21,7 +21,7 @@ The children property can contain various inline content elements.
diff --git a/api/types/index.IRunStylePropertiesOptions.html b/api/types/index.IRunStylePropertiesOptions.html
index 76d2f1c99e..f0aabd7811 100644
--- a/api/types/index.IRunStylePropertiesOptions.html
+++ b/api/types/index.IRunStylePropertiesOptions.html
@@ -19,7 +19,7 @@ including font, size, bold, italic, underline, color, and other character format
@@ -140,117 +140,117 @@ including font, size, bold, italic, underline, color, and other character format
highlights all the run's text. docx used to write it as w:highlightCs, which is in no schema.
diff --git a/api/types/index.ITableCellBorders.html b/api/types/index.ITableCellBorders.html
index f90ce3f76e..37ee2fea0e 100644
--- a/api/types/index.ITableCellBorders.html
+++ b/api/types/index.ITableCellBorders.html
@@ -22,7 +22,7 @@ can be specified for top, bottom, left, right, start, and end edges.
@@ -46,7 +46,7 @@ If relativeHorizontalPosition is also specified, then the absoluteHorizontalPosi
If the attribute is omitted, the value is assumed to be zero.
@@ -57,7 +57,7 @@ If relativeVerticalPosition is also specified, then the absoluteVerticalPosition
If the attribute is omitted, the value is assumed to be zero.
@@ -65,7 +65,7 @@ If the attribute is omitted, the value is assumed to be zero.
below the table. The value is in twentieths of a point. If omitted, the value is assumed to be zero.
+
@@ -85,7 +85,7 @@ If omitted, the value is assumed to be page.
to the left of the table. The value is in twentieths of a point. If omitted, the value is assumed to be zero.
+
@@ -121,7 +121,7 @@ inline - the table should be vertically aligned in line with the surrounding tex
top - the table should be vertically aligned to the top edge of the anchor
+
@@ -129,7 +129,7 @@ top - the table should be vertically aligned to the top edge of the anchor
to the right of the table. The value is in twentieths of a point. If omitted, the value is assumed to be zero.
+
@@ -137,7 +137,7 @@ to the right of the table. The value is in twentieths of a point. If omitted, th
above the table. The value is in twentieths of a point. If omitted, the value is assumed to be zero.
+
@@ -88,7 +88,7 @@ When true, horizontal banding (alternating row colors) is disabled.
When false or undefined, horizontal banding is enabled if defined in the table style.
+
@@ -97,7 +97,7 @@ When true, vertical banding (alternating column colors) is disabled.
When false or undefined, vertical banding is enabled if defined in the table style.
+
diff --git a/api/types/index.ITableOfContentsOptions.html b/api/types/index.ITableOfContentsOptions.html
index ff08dd1c02..dc267322da 100644
--- a/api/types/index.ITableOfContentsOptions.html
+++ b/api/types/index.ITableOfContentsOptions.html
@@ -23,7 +23,7 @@ Options correspond to field switches in the TOC field code.
@@ -59,7 +59,7 @@ The identifier designated by text in this switch's field-argument corresponds to
Use captionLabelIncludingNumbers (\c) to build a table of captions with labels and numbers.
@@ -85,7 +85,7 @@ the bookmark named by text in this switch's field-argument.
that separate an entry and its page number. The default is a tab with leader dots.
+
@@ -96,21 +96,21 @@ to the style with a style ID of HeadingX (e.g. 1 corresponds to Heading1).
If no heading range is specified, all heading levels used in the document are listed.
+
@@ -119,21 +119,21 @@ Page numbers are omitted from all levels unless a range of entry levels is speci
text in this switch's field-argument. A range is specified as for \l.
+
@@ -168,7 +168,7 @@ with each doublet being a comma-separated set of style name and table of content
text in this switch's field-argument (which is typically a letter).
+
@@ -178,14 +178,14 @@ where startLevel and endLevel are integers, and startLevel has a value equal-to
TC fields that assign entries to lower levels are skipped.
+
@@ -76,64 +76,64 @@ parent cell) when the document is packed, so the table renders the same in every
consumer. Supply explicit values to take full control of the grid.
diff --git a/api/types/index.IThemeColorsOptions.html b/api/types/index.IThemeColorsOptions.html
index e3153a75b7..9f88afa8e5 100644
--- a/api/types/index.IThemeColorsOptions.html
+++ b/api/types/index.IThemeColorsOptions.html
@@ -21,7 +21,7 @@ when the theme's colors change. The colors not given are Office's.
diff --git a/api/types/index.IXmlAttribute.html b/api/types/index.IXmlAttribute.html
index 0fc1a243de..514651203a 100644
--- a/api/types/index.IXmlAttribute.html
+++ b/api/types/index.IXmlAttribute.html
@@ -17,7 +17,7 @@
numbers, or booleans, which will be converted to strings in the final XML.
diff --git a/api/types/index.MathRunStyle.html b/api/types/index.MathRunStyle.html
index 5f8d8bd2eb..f849022d46 100644
--- a/api/types/index.MathRunStyle.html
+++ b/api/types/index.MathRunStyle.html
@@ -23,7 +23,7 @@
alphabet other than roman is plain unless given a style, as LaTeX draws its alphabets upright.
diff --git a/api/types/index.OutputByType.html b/api/types/index.OutputByType.html
index d399169d26..c200e6f456 100644
--- a/api/types/index.OutputByType.html
+++ b/api/types/index.OutputByType.html
@@ -24,7 +24,7 @@ format determines the return type. Based on JSZip's output types.
diff --git a/api/types/index.PageNumberEstimator.html b/api/types/index.PageNumberEstimator.html
index 61f02aae61..bff62610f7 100644
--- a/api/types/index.PageNumberEstimator.html
+++ b/api/types/index.PageNumberEstimator.html
@@ -38,7 +38,7 @@ page counts can be written with it.
diff --git a/api/types/index.ParagraphChild.html b/api/types/index.ParagraphChild.html
index 64566139f1..3adbab416e 100644
--- a/api/types/index.ParagraphChild.html
+++ b/api/types/index.ParagraphChild.html
@@ -17,7 +17,7 @@ This union type represents all valid inline content elements that can appear
within a paragraph in WordprocessingML.
@@ -57,7 +57,7 @@ when it opens it, unzipped and read as the template is, by its path in the templ
(captureSpacesBetweenElements), as the spaces in a text element are its text
diff --git a/api/types/index.RelationshipType.html b/api/types/index.RelationshipType.html
index ba1d82f86a..f9d08b846f 100644
--- a/api/types/index.RelationshipType.html
+++ b/api/types/index.RelationshipType.html
@@ -17,7 +17,7 @@
Each type corresponds to a specific kind of document component or resource.
diff --git a/api/types/index.TableRowsPatch.html b/api/types/index.TableRowsPatch.html
index babb0d1cf7..4b31a8719d 100644
--- a/api/types/index.TableRowsPatch.html
+++ b/api/types/index.TableRowsPatch.html
@@ -32,7 +32,7 @@ none. The other patches are applied after the rows are repeated, so a placeholde
@@ -55,14 +55,14 @@ A field's patch can repeat rows of a table in the copy in turn, whose fields are
repeated for each part, with its item's fields, and an item without parts has no row
diff --git a/api/types/index.TemplatePageNumberEstimator.html b/api/types/index.TemplatePageNumberEstimator.html
index 9072da4475..5661bcfd46 100644
--- a/api/types/index.TemplatePageNumberEstimator.html
+++ b/api/types/index.TemplatePageNumberEstimator.html
@@ -33,7 +33,7 @@ pages, are written with it.
Specifies the height of the containing block of the shape. Default is 0. It is specified in CSS units or, for elements in a group, in the coordinate system of the parent element.
Specifies the position of the left of the containing block of the shape relative to the element left of it in the flow of the page. Default is 0. It is specified in CSS units or, for elements in a group, in the coordinate system of the parent element. This property shall not be used for shapes anchored inline.
Specifies the position of the bottom of the containing block of the shape relative to the shape anchor. Default is 0. It is specified in CSS units or, for elements in a group, in the coordinate system of the parent element.
Specifies the position of the left of the containing block of the shape relative to the shape anchor. Default is 0. It is specified in CSS units or, for elements in a group, in the coordinate system of the parent element.
Specifies the position of the right of the containing block of the shape relative to the shape anchor. Default is 0. It is specified in CSS units or, for elements in a group, in the coordinate system of the parent element.
Specifies the position of the top of the containing block of the shape relative to the shape anchor. Default is 0. It is specified in CSS units or, for elements in a group, in the coordinate system of the parent element.
Specifies the type of positioning used to place an element. Default is static. When the element is contained inside a group, this property must be absolute.
Specifies relative horizontal position data for objects in WordprocessingML documents. This modifies the mso-position-horizontal property. Default is text.
Specifies relative vertical position data for objects in WordprocessingML documents. This modifies the mso-position-vertical property. Default is text.
Specifies the position of the top of the containing block of the shape relative to the element above it in the flow of the page. Default is 0. It is specified in CSS units or, for elements in a group, in the coordinate system of the parent element. This property shall not be used for shapes anchored inline.
Specifies the width of the containing block of the shape. Default is 0. It is specified in CSS units or, for elements in a group, in the coordinate system of the parent element.
Specifies the distance from the bottom of the shape to the text that wraps around it. Default is 0 pt. Note that this property is different from the CSS margin property, which changes the origin of the shape to include the margin areas. This property does not change the origin.
Specifies the distance from the left side of the shape to the text that wraps around it. Default is 0 pt. Note that this property is different from the CSS margin property, which changes the origin of the shape to include the margin areas. This property does not change the origin.
Specifies the distance from the right side of the shape to the text that wraps around it. Default is 0 pt. Note that this property is different from the CSS margin property, which changes the origin of the shape to include the margin areas. This property does not change the origin.
Specifies the distance from the top of the shape to the text that wraps around it. Default is 0 pt. Note that this property is different from the CSS margin property, which changes the origin of the shape to include the margin areas. This property does not change the origin.
Specifies whether the wrap coordinates were customized by the user. If the wrap coordinates are generated by an editor, this property is true; otherwise they were customized by a user. Default is false.
@@ -63,7 +63,7 @@ nearest to Word's lays it out. It still stops where it has no guess, such as at
is off, so the numbers written are Word's, as near as the layout knows, or blank.
+
@@ -73,7 +73,7 @@ break, and tabs move to their stops, as Word lays them out, and lines are as tal
width tables, so the layout stops at text in a font that isn't in them and isn't given as a file or embedded.
+
diff --git a/api/types/layout.MeasureWidth.html b/api/types/layout.MeasureWidth.html
index 73aea12d87..efb3139b05 100644
--- a/api/types/layout.MeasureWidth.html
+++ b/api/types/layout.MeasureWidth.html
@@ -33,7 +33,7 @@ between characters and the width of scaled text, which the document's formatting
diff --git a/api/types/shapes.ConnectorEnd.html b/api/types/shapes.ConnectorEnd.html
index c160f09623..14ca268dab 100644
--- a/api/types/shapes.ConnectorEnd.html
+++ b/api/types/shapes.ConnectorEnd.html
@@ -38,7 +38,7 @@ bottom-left corner. On a shape without connection points, the connector ends at
diff --git a/api/types/shapes.CustomShapeGeometry.html b/api/types/shapes.CustomShapeGeometry.html
index f9e91bc029..091be40117 100644
--- a/api/types/shapes.CustomShapeGeometry.html
+++ b/api/types/shapes.CustomShapeGeometry.html
@@ -50,7 +50,7 @@ fill the shape. Later paths are drawn over earlier ones
diff --git a/api/types/shapes.CustomShapePath.html b/api/types/shapes.CustomShapePath.html
index cab18cb309..bff6e8264c 100644
--- a/api/types/shapes.CustomShapePath.html
+++ b/api/types/shapes.CustomShapePath.html
@@ -20,7 +20,7 @@ own, so paths can overlap without cutting holes in each other.
diff --git a/api/types/shapes.CustomShapePathFill.html b/api/types/shapes.CustomShapePathFill.html
index a00e95ea2e..17fe5ec7a3 100644
--- a/api/types/shapes.CustomShapePathFill.html
+++ b/api/types/shapes.CustomShapePathFill.html
@@ -19,7 +19,7 @@ fill made lighter or darker, as Word's preset shapes shade the top of a cube or
diff --git a/api/types/shapes.IShapeCanvasOptions.html b/api/types/shapes.IShapeCanvasOptions.html
index fbc74c7a61..ed16e3bd21 100644
--- a/api/types/shapes.IShapeCanvasOptions.html
+++ b/api/types/shapes.IShapeCanvasOptions.html
@@ -64,7 +64,7 @@ The shapes are not scaled.
diff --git a/api/types/shapes.IShapeConnectorOptions.html b/api/types/shapes.IShapeConnectorOptions.html
index 843a04b990..6b6718d010 100644
--- a/api/types/shapes.IShapeConnectorOptions.html
+++ b/api/types/shapes.IShapeConnectorOptions.html
@@ -23,7 +23,7 @@ or several connectors join the same two shapes, their ends are spread out along
@@ -64,21 +64,21 @@ or several connectors join the same two shapes, their ends are spread out along
shape, so Word doesn't move it when the connector moves
diff --git a/api/types/shapes.IShapeGroupChildOptions.html b/api/types/shapes.IShapeGroupChildOptions.html
index 0c0d5e931f..7d74df4bd8 100644
--- a/api/types/shapes.IShapeGroupChildOptions.html
+++ b/api/types/shapes.IShapeGroupChildOptions.html
@@ -20,7 +20,7 @@ in pixels, unless a layout places it, and id names it
diff --git a/api/types/shapes.IShapeGroupOptions.html b/api/types/shapes.IShapeGroupOptions.html
index 77275636f9..cc87ce299a 100644
--- a/api/types/shapes.IShapeGroupOptions.html
+++ b/api/types/shapes.IShapeGroupOptions.html
@@ -50,7 +50,7 @@ the box around the children. A different size scales every shape in the group.
diff --git a/api/types/shapes.IShapeNestedGroupOptions.html b/api/types/shapes.IShapeNestedGroupOptions.html
index d04a69440a..cdc8494590 100644
--- a/api/types/shapes.IShapeNestedGroupOptions.html
+++ b/api/types/shapes.IShapeNestedGroupOptions.html
@@ -47,7 +47,7 @@ box around the children, and a different size scales every child
diff --git a/api/types/shapes.IShapeOptions.html b/api/types/shapes.IShapeOptions.html
index 080d62ed28..f46d3fbacc 100644
--- a/api/types/shapes.IShapeOptions.html
+++ b/api/types/shapes.IShapeOptions.html
@@ -23,7 +23,7 @@ or startAngle and endAngle for a "pie"
diff --git a/api/types/shapes.PresetShapeAdjustments.html b/api/types/shapes.PresetShapeAdjustments.html
index 0f4de8cd88..beaacacacb 100644
--- a/api/types/shapes.PresetShapeAdjustments.html
+++ b/api/types/shapes.PresetShapeAdjustments.html
@@ -21,7 +21,7 @@ allows, so a value that is too large acts like the largest allowed value.
diff --git a/api/types/shapes.ShapeAdjustments.html b/api/types/shapes.ShapeAdjustments.html
index 40a3fd47bb..409947af73 100644
--- a/api/types/shapes.ShapeAdjustments.html
+++ b/api/types/shapes.ShapeAdjustments.html
@@ -23,7 +23,7 @@ It is never for shapes without handles, which take no adjustments.<
diff --git a/api/types/shapes.ShapeFlowLayout.html b/api/types/shapes.ShapeFlowLayout.html
index a178912357..3c94771909 100644
--- a/api/types/shapes.ShapeFlowLayout.html
+++ b/api/types/shapes.ShapeFlowLayout.html
@@ -20,7 +20,7 @@ that connect to it, and the shapes on each level are ordered so connectors cross
@@ -52,26 +52,26 @@ with a lane goes in the band of that name, and shapes without one g
across the direction the flow runs in, each with a header at the start of the flow
diff --git a/api/types/shapes.ShapeHorizontalPosition.html b/api/types/shapes.ShapeHorizontalPosition.html
index ed18f2e06c..2f754797b8 100644
--- a/api/types/shapes.ShapeHorizontalPosition.html
+++ b/api/types/shapes.ShapeHorizontalPosition.html
@@ -26,7 +26,7 @@ a base of the page, the space between its margins, or one of its margins
diff --git a/api/types/shapes.ShapeLayout.html b/api/types/shapes.ShapeLayout.html
index 26cf8ec174..2e3e3438ba 100644
--- a/api/types/shapes.ShapeLayout.html
+++ b/api/types/shapes.ShapeLayout.html
@@ -20,7 +20,7 @@ layout, which is placed around them. Connectors are routed after the shapes are
diff --git a/api/types/shapes.ShapeSize.html b/api/types/shapes.ShapeSize.html
index 8b2a52fb80..cd98ea6693 100644
--- a/api/types/shapes.ShapeSize.html
+++ b/api/types/shapes.ShapeSize.html
@@ -19,7 +19,7 @@ percentage of the space between the page's margins, or of what floating.si
diff --git a/api/types/shapes.ShapeTextWarp.html b/api/types/shapes.ShapeTextWarp.html
index ca20aa3bf6..5eb8e914d8 100644
--- a/api/types/shapes.ShapeTextWarp.html
+++ b/api/types/shapes.ShapeTextWarp.html
@@ -19,7 +19,7 @@ The ...Filled arches, circle and button spread the text over the wh
diff --git a/api/types/shapes.ShapeThemeColor.html b/api/types/shapes.ShapeThemeColor.html
index 23f6261307..3ac6400e70 100644
--- a/api/types/shapes.ShapeThemeColor.html
+++ b/api/types/shapes.ShapeThemeColor.html
@@ -20,7 +20,7 @@ same as docx's ThemeColor, which text, borders and sha
diff --git a/api/types/shapes.ShapeTransformation.html b/api/types/shapes.ShapeTransformation.html
index 999db2eae3..8c8fcbbe01 100644
--- a/api/types/shapes.ShapeTransformation.html
+++ b/api/types/shapes.ShapeTransformation.html
@@ -30,7 +30,7 @@ between the margins for a floating shape, such as "100%"<
diff --git a/api/types/shapes.ShapeTreeLayout.html b/api/types/shapes.ShapeTreeLayout.html
index a57ab50a7c..18d0d45aea 100644
--- a/api/types/shapes.ShapeTreeLayout.html
+++ b/api/types/shapes.ShapeTreeLayout.html
@@ -20,7 +20,7 @@ children are placed side by side below their parent, which is centred over them.
diff --git a/api/types/shapes.ShapeVerticalPosition.html b/api/types/shapes.ShapeVerticalPosition.html
index 8aad678d5f..56c93b3b5f 100644
--- a/api/types/shapes.ShapeVerticalPosition.html
+++ b/api/types/shapes.ShapeVerticalPosition.html
@@ -26,7 +26,7 @@ a base of the page, the space between its margins, or one of its margins
diff --git a/api/variables/index.CharacterSet.html b/api/variables/index.CharacterSet.html
index 1a765840ad..9036908843 100644
--- a/api/variables/index.CharacterSet.html
+++ b/api/variables/index.CharacterSet.html
@@ -60,7 +60,7 @@ Maps character set names to their hexadecimal identifiers.
diff --git a/api/variables/index.DocumentAttributeNamespaces.html b/api/variables/index.DocumentAttributeNamespaces.html
index a3769a5dbe..5aca1592a9 100644
--- a/api/variables/index.DocumentAttributeNamespaces.html
+++ b/api/variables/index.DocumentAttributeNamespaces.html
@@ -94,7 +94,7 @@ in a document, including WordprocessingML, DrawingML, VML, and others.
When this value is set, the input specified via the user interface may be restricted to the number of lines per page and characters per line, with the consumer or producer translating this information based on the current font data to get the resulting line and character pitch values
diff --git a/api/variables/index.DropCapType.html b/api/variables/index.DropCapType.html
index 511e3b9c9b..c1258cea69 100644
--- a/api/variables/index.DropCapType.html
+++ b/api/variables/index.DropCapType.html
@@ -32,7 +32,7 @@ beginning of a paragraph. This enum defines how the drop cap should be positione
diff --git a/api/variables/index.EMPTY_OBJECT.html b/api/variables/index.EMPTY_OBJECT.html
index f15d71244f..d7cd6645b0 100644
--- a/api/variables/index.EMPTY_OBJECT.html
+++ b/api/variables/index.EMPTY_OBJECT.html
@@ -20,7 +20,7 @@ has no children or attributes.
diff --git a/api/variables/index.EmphasisMarkType.html b/api/variables/index.EmphasisMarkType.html
index 93bd6f0a43..14c114c516 100644
--- a/api/variables/index.EmphasisMarkType.html
+++ b/api/variables/index.EmphasisMarkType.html
@@ -31,7 +31,7 @@ Emphasis marks are commonly used in East Asian typography.
Specifies that this header or footer shall appear on the first page in this section. The appearance of this header or footer is contingent on the setting of the titlePg element (§2.10.6).
diff --git a/api/variables/index.LevelFormat.html b/api/variables/index.LevelFormat.html
index aa298edcea..8b48cf5784 100644
--- a/api/variables/index.LevelFormat.html
+++ b/api/variables/index.LevelFormat.html
@@ -281,7 +281,7 @@ decimal, roman numerals, letters, and various international formats.
diff --git a/api/variables/index.PageTextDirectionType.html b/api/variables/index.PageTextDirectionType.html
index 7b52d59f3f..81b8634ea9 100644
--- a/api/variables/index.PageTextDirectionType.html
+++ b/api/variables/index.PageTextDirectionType.html
@@ -28,7 +28,7 @@ vertically (top-to-bottom), commonly used for East Asian languages.
Top-to-bottom, right-to-left (vertical East Asian text flow)
diff --git a/api/variables/index.ShadingType.html b/api/variables/index.ShadingType.html
index d2e1524943..a41f2e4b9e 100644
--- a/api/variables/index.ShadingType.html
+++ b/api/variables/index.ShadingType.html
@@ -103,7 +103,7 @@ color and the pattern color.
diff --git a/api/variables/index.TextEffect.html b/api/variables/index.TextEffect.html
index 26ff6ed312..98113a56b4 100644
--- a/api/variables/index.TextEffect.html
+++ b/api/variables/index.TextEffect.html
@@ -56,7 +56,7 @@ these effects are deprecated and may not be supported by all applications.
diff --git a/api/variables/index.VerticalAlign.html b/api/variables/index.VerticalAlign.html
index b00a08c8e7..26133f4eab 100644
--- a/api/variables/index.VerticalAlign.html
+++ b/api/variables/index.VerticalAlign.html
@@ -32,7 +32,7 @@ backward-compatibility and will be removed in the next major release.
diff --git a/api/variables/index.VerticalAlignTable.html b/api/variables/index.VerticalAlignTable.html
index f0ac90bf1a..a5102011d4 100644
--- a/api/variables/index.VerticalAlignTable.html
+++ b/api/variables/index.VerticalAlignTable.html
@@ -28,7 +28,7 @@ are valid according to ECMA-376 (§17.18.87 ST_VerticalJc within <w:tcP
diff --git a/api/variables/index.VerticalMergeType.html b/api/variables/index.VerticalMergeType.html
index 1e5af837c0..2c18c952ec 100644
--- a/api/variables/index.VerticalMergeType.html
+++ b/api/variables/index.VerticalMergeType.html
@@ -29,7 +29,7 @@ This cell continues a vertical merge started by a cell above it.
This cell begins a new vertical merge region.
diff --git a/api/variables/index.bookmarkUniqueNumericId.html b/api/variables/index.bookmarkUniqueNumericId.html
index daa7c5090f..fcdc18fd10 100644
--- a/api/variables/index.bookmarkUniqueNumericId.html
+++ b/api/variables/index.bookmarkUniqueNumericId.html
@@ -27,7 +27,7 @@ than a generator per instance.
diff --git a/api/variables/index.docPropertiesUniqueNumericId.html b/api/variables/index.docPropertiesUniqueNumericId.html
index a77b4924c7..455e9b0d2c 100644
--- a/api/variables/index.docPropertiesUniqueNumericId.html
+++ b/api/variables/index.docPropertiesUniqueNumericId.html
@@ -28,7 +28,7 @@ one counter rather than a generator per instance.
diff --git a/api/variables/layout.estimatePageNumbers.html b/api/variables/layout.estimatePageNumbers.html
index 91683eaed8..bae006e22d 100644
--- a/api/variables/layout.estimatePageNumbers.html
+++ b/api/variables/layout.estimatePageNumbers.html
@@ -51,7 +51,7 @@ written, and the numbers left blank stay blank, without asking to update the fie
diff --git a/live-examples/lib/layout.iife.js b/live-examples/lib/layout.iife.js
index 6b47fa39f8..63b998aead 100644
--- a/live-examples/lib/layout.iife.js
+++ b/live-examples/lib/layout.iife.js
@@ -7233,7 +7233,7 @@ var docxLayout = (function(exports) {
const before = characters[index - 1];
const after = characters[index];
if (isExtender(after) || joinsNext$1(before) || GLUE.has(before) || GLUE.has(after)) continue;
- if ((before === ZERO_WIDTH_SPACE || DASHES.has(before) && !/[\d-]/.test(after) || breaksAround(before) || breaksAround(after) || runs[index - 1].anywhere && runs[index].anywhere) && !(kinsoku && (listAt(index).noLineStart.has(after) || listAt(index - 1).noLineEnd.has(before)))) breaks.add(index);
+ if ((before === ZERO_WIDTH_SPACE || DASHES.has(before) && !/[\d-]/.test(after) || rules.ideographs !== false && (breaksAround(before) || breaksAround(after)) || runs[index - 1].anywhere && runs[index].anywhere) && !(kinsoku && (listAt(index).noLineStart.has(after) || listAt(index - 1).noLineEnd.has(before)))) breaks.add(index);
}
return breaks;
};
@@ -7902,7 +7902,6 @@ var docxLayout = (function(exports) {
};
var DEFAULT_TAB_STOP = 36;
var TOLERANCE$2 = .01;
- var OLDER_PAGE_BREAK = "a page break at the end of a paragraph in a document in compatibility mode";
var STRETCH_TO_SQUEEZE = 2.015;
var MOST_SQUEEZE = .25;
var MAY_HYPHENATE = "a word Word may hyphenate, whose parts the layout can't know";
@@ -8826,8 +8825,7 @@ var docxLayout = (function(exports) {
const { stops, firstLineStops } = stopsOf(tabStops, format);
const parts = segmentsOf(content, rulesOf(format, breakRules));
const [previous, last] = parts.slice(-2);
- const endsWithBreak = parts.length > 1 && previous.end.kind === "page" && last.tokens.every((token) => token.type === "marker");
- const segments = endsWithBreak ? [...parts.slice(0, -2), {
+ const segments = parts.length > 1 && previous.end.kind === "page" && last.tokens.every((token) => token.type === "marker") ? [...parts.slice(0, -2), {
tokens: [...previous.tokens, ...last.tokens],
end: previous.end
}] : parts;
@@ -8860,9 +8858,10 @@ var docxLayout = (function(exports) {
};
/**
* Where the line being filled ends: the margin after a tab to one of the paragraph's stops past its right indent, which
- * Word lines text up with on the line (scripts/layout-probes/word-breaks-and-tabs.ts TP6, TP9)
+ * Word lines text up with on the line (scripts/layout-probes/word-breaks-and-tabs.ts TP6, TP9), and nowhere after a tab
+ * past its end in a document in compatibility mode
*/
- const endOf = (state) => state.pastIndent ? marginOf() : limitOf();
+ const endOf = (state) => state.unbroken ? Infinity : state.pastIndent ? marginOf() : limitOf();
/**
* Whether Word squeezes a word or picture this wide onto a justified or distributed line it goes past the end of,
* rather than move it to the next line. It squeezes the line's spaces in proportion to their widths, and does when that
@@ -8950,7 +8949,7 @@ var docxLayout = (function(exports) {
first
}, unknownOnGrid === void 0 ? {} : { unsupported: unknownOnGrid });
const finish = (state, breakAfter) => {
- var _state$unsupported;
+ var _ref5, _state$unsupported;
const spacing = lineSpacingFrom !== void 0 && [
...lines.flatMap(({ markers }) => markers),
...state.markers,
@@ -8959,7 +8958,7 @@ var docxLayout = (function(exports) {
const marked = state.started ? withMarkOf(state.heights) : markHeightsOf();
const heights = typeof marked === "string" ? state.heights : marked;
const _ref4 = linePitch === void 0 ? heightOf(heights, spacing) : gridHeightOf(heights, spacing, linePitch), { unsupported: unknownHeight } = _ref4, height = _objectWithoutProperties(_ref4, _excluded$1);
- const unsupported = state.unknown ? "a justified line that only fits squeezed at a four-per-em space, or at an en, em or ideographic space beside ordinary spaces" : (_state$unsupported = state.unsupported) !== null && _state$unsupported !== void 0 ? _state$unsupported : markMatters(withNumber(heights)) ? "a picture alone in a line of a paragraph whose mark is larger, with multiple line spacing" : typeof marked === "string" ? marked : unknownHeight;
+ const unsupported = state.unknown ? "a justified line that only fits squeezed at a four-per-em space, or at an en, em or ideographic space beside ordinary spaces" : (_ref5 = (_state$unsupported = state.unsupported) !== null && _state$unsupported !== void 0 ? _state$unsupported : state.unbroken && state.end > 941.41 ? "text after a tab past the end of the line that goes further past the margin than Word was seen keeping it on the line, in a document in compatibility mode" : void 0) !== null && _ref5 !== void 0 ? _ref5 : markMatters(withNumber(heights)) ? "a picture alone in a line of a paragraph whose mark is larger, with multiple line spacing" : typeof marked === "string" ? marked : unknownHeight;
lines.push(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({}, height), {}, { markers: [...state.markers, ...state.pending] }, breakAfter ? { breakAfter } : {}), {}, {
text: state.text,
textWidth: Math.max(0, state.end - state.start)
@@ -9243,13 +9242,14 @@ var docxLayout = (function(exports) {
}
if (snapping && token.type !== "word") line = _objectSpread2(_objectSpread2({}, line), {}, { latin: void 0 });
if (token.type === "tab") {
- var _nextStop, _line$unsupported21;
+ var _nextStop, _line$unsupported20;
const numbered = numberTab ? { stop: numberTabStop(line.position, firstLineStops, format, defaultTabStop, limitOf()) } : void 0;
numberTab = false;
const given = line.first ? firstLineStops : stops;
const next = nextStop(line.position, given, defaultTabStop, Infinity);
const rest = tokens.slice(index + 1);
- const own = !numbered && given.includes(next);
+ const olderPast = older && !numbered && next.position > limitOf() + TOLERANCE$2;
+ const own = !numbered && !olderPast && given.includes(next);
const pastIndent = own && indentRight > 0 && next.position > limitOf() + TOLERANCE$2 && next.position <= marginOf() + TOLERANCE$2;
const pastEnd = own && next.position > Math.max(limitOf(), marginOf()) + TOLERANCE$2 ? next : void 0;
const unknown = pastIndent && squeezes && alignment !== "justified" ? "a tab stop past the paragraph's right indent in a distributed line" : pastIndent && next.alignment === "left" && next.position + widthAfterTab(rest, measurer) > marginOf() + TOLERANCE$2 ? "text after a tab stop past the paragraph's right indent that goes past the margin" : pastEnd === void 0 ? void 0 : pastEndUnknown(pastEnd, line.started);
@@ -9257,10 +9257,6 @@ var docxLayout = (function(exports) {
var _line$unsupported15;
line = _objectSpread2(_objectSpread2({}, line), {}, { unsupported: (_line$unsupported15 = line.unsupported) !== null && _line$unsupported15 !== void 0 ? _line$unsupported15 : unknown });
}
- if (older && !numbered && next.position > limitOf() + TOLERANCE$2) {
- var _line$unsupported16;
- line = _objectSpread2(_objectSpread2({}, line), {}, { unsupported: (_line$unsupported16 = line.unsupported) !== null && _line$unsupported16 !== void 0 ? _line$unsupported16 : "a tab past the end of the line in a document in compatibility mode" });
- }
if ((pastEnd === null || pastEnd === void 0 ? void 0 : pastEnd.alignment) === "left" && unknown === void 0) {
const below = line.started ? wrap(line) : line;
line = wrap(place(_objectSpread2(_objectSpread2({}, below), {}, {
@@ -9272,18 +9268,18 @@ var docxLayout = (function(exports) {
}
const aligned = pastEnd !== void 0 && pastEnd.alignment !== "left" && unknown === void 0;
if (aligned && line.position + widthAfterTab(rest, measurer) > limitOf() + TOLERANCE$2) line = wrap(line);
- let stop = numbered ? numbered.stop : aligned ? {
+ let stop = numbered ? numbered.stop : olderPast ? next : aligned ? {
position: limitOf(),
alignment: "right"
} : pastIndent ? next : (_nextStop = nextStop(line.position, given, defaultTabStop, limitOf())) !== null && _nextStop !== void 0 ? _nextStop : line.started ? nextStop(startOf(lines.length + 1, false), stops, defaultTabStop, limitOf(lines.length + 1)) : void 0;
if (stop === void 0) {
- var _line$unsupported17;
+ var _line$unsupported16;
line = _objectSpread2(_objectSpread2({}, line), {}, {
end: line.position,
text: `${line.text}\t`,
heights: withToken(line.heights, token),
started: true
- }, !snapping ? {} : { unsupported: (_line$unsupported17 = line.unsupported) !== null && _line$unsupported17 !== void 0 ? _line$unsupported17 : GRID_TAB });
+ }, !snapping ? {} : { unsupported: (_line$unsupported16 = line.unsupported) !== null && _line$unsupported16 !== void 0 ? _line$unsupported16 : GRID_TAB });
continue;
}
if (!numbered && stop.position <= line.position + TOLERANCE$2) line = wrap(line);
@@ -9310,7 +9306,7 @@ var docxLayout = (function(exports) {
};
};
const after = rest.find((other) => other.type !== "marker");
- if (!numbered && token.font.listNumber !== "separator" && !aligned && !pastIndent && line.started && line.tabsOnly !== true && ((after === null || after === void 0 ? void 0 : after.type) === "word" || (after === null || after === void 0 ? void 0 : after.type) === "box")) {
+ if (!numbered && !olderPast && token.font.listNumber !== "separator" && !aligned && !pastIndent && line.started && line.tabsOnly !== true && ((after === null || after === void 0 ? void 0 : after.type) === "word" || (after === null || after === void 0 ? void 0 : after.type) === "box")) {
var _after$hyphens, _lastBorder$room4, _lastBorder4, _tokens$slice$findLas;
const hyphen = after.type === "word" ? (_after$hyphens = after.hyphens) === null || _after$hyphens === void 0 ? void 0 : _after$hyphens.find(({ at }) => at > 0 && at < lengthOf(after.pieces)) : void 0;
const needs = after.type === "box" ? after.width : roomBetween(line.border, firstBorder(after.pieces)) + (hyphen === void 0 ? widthOf(after.pieces, measurer) + ((_lastBorder$room4 = (_lastBorder4 = lastBorder(after.pieces)) === null || _lastBorder4 === void 0 ? void 0 : _lastBorder4.room) !== null && _lastBorder$room4 !== void 0 ? _lastBorder$room4 : 0) : widthOf(splitPieces(after.pieces, hyphen.at)[0], measurer) + measurer.measureWidth("-", hyphen.font));
@@ -9318,24 +9314,24 @@ var docxLayout = (function(exports) {
const inRow = ((_tokens$slice$findLas = tokens.slice(0, index).findLast((before) => before.type !== "marker")) === null || _tokens$slice$findLas === void 0 ? void 0 : _tokens$slice$findLas.type) === "tab";
if (startAt(stop, line).position + needs > endOf(line) + TOLERANCE$2 && nextLine !== void 0) {
if (after.type === "box" || inRow) {
- var _line$unsupported18;
- line = _objectSpread2(_objectSpread2({}, line), {}, { unsupported: (_line$unsupported18 = line.unsupported) !== null && _line$unsupported18 !== void 0 ? _line$unsupported18 : inRow ? "a word that doesn't fit after tabs in a row" : "a picture that doesn't fit after a tab" });
+ var _line$unsupported17;
+ line = _objectSpread2(_objectSpread2({}, line), {}, { unsupported: (_line$unsupported17 = line.unsupported) !== null && _line$unsupported17 !== void 0 ? _line$unsupported17 : inRow ? "a word that doesn't fit after tabs in a row" : "a picture that doesn't fit after a tab" });
} else {
if (hyphen !== void 0) {
- var _line$unsupported19;
- line = _objectSpread2(_objectSpread2({}, line), {}, { unsupported: (_line$unsupported19 = line.unsupported) !== null && _line$unsupported19 !== void 0 ? _line$unsupported19 : "a word with soft hyphens whose first part doesn't fit after a tab" });
+ var _line$unsupported18;
+ line = _objectSpread2(_objectSpread2({}, line), {}, { unsupported: (_line$unsupported18 = line.unsupported) !== null && _line$unsupported18 !== void 0 ? _line$unsupported18 : "a word with soft hyphens whose first part doesn't fit after a tab" });
}
line = wrap(line);
stop = nextLine;
}
}
}
- line = _objectSpread2(_objectSpread2({}, place(line)), pastIndent ? { pastIndent } : {});
+ line = _objectSpread2(_objectSpread2(_objectSpread2({}, place(line)), pastIndent ? { pastIndent } : {}), olderPast ? { unbroken: olderPast } : {});
const { lineUp, position } = startAt(stop, line);
const misaligned = lineUp === void 0 ? "text at a decimal tab stop that Word hasn't been seen lining up" : void 0;
if (snapping && !inCells(stop) && (stop.alignment !== "left" || starting === void 0)) {
- var _line$unsupported20;
- line = _objectSpread2(_objectSpread2({}, line), {}, { unsupported: (_line$unsupported20 = line.unsupported) !== null && _line$unsupported20 !== void 0 ? _line$unsupported20 : GRID_TAB });
+ var _line$unsupported19;
+ line = _objectSpread2(_objectSpread2({}, line), {}, { unsupported: (_line$unsupported19 = line.unsupported) !== null && _line$unsupported19 !== void 0 ? _line$unsupported19 : GRID_TAB });
}
line = _objectSpread2(_objectSpread2({}, line), {}, {
position,
@@ -9349,7 +9345,7 @@ var docxLayout = (function(exports) {
otherSpaces: 0,
started: true,
tabsOnly: !line.started || line.tabsOnly === true
- }, misaligned === void 0 ? {} : { unsupported: (_line$unsupported21 = line.unsupported) !== null && _line$unsupported21 !== void 0 ? _line$unsupported21 : misaligned });
+ }, misaligned === void 0 ? {} : { unsupported: (_line$unsupported20 = line.unsupported) !== null && _line$unsupported20 !== void 0 ? _line$unsupported20 : misaligned });
continue;
}
const [space, nextWord] = token.type === "word" && format.rightToLeft !== true ? nextTwo(tokens, index) : [];
@@ -9367,7 +9363,7 @@ var docxLayout = (function(exports) {
}
first = false;
}
- return older && endsWithBreak ? lines.map((line, index) => index === lines.length - 1 ? _objectSpread2(_objectSpread2({}, line), {}, { unsupported: OLDER_PAGE_BREAK }) : line) : lines;
+ return lines;
};
//#endregion
//#region src/text-layout/office-cloud-fonts.ts
@@ -11640,10 +11636,10 @@ var docxLayout = (function(exports) {
if (tooLong.length === 0 && !spaced && !widen.uneven && widen.width === void 0) return table;
if (tooLong.some(({ vertical }) => vertical)) return _objectSpread2(_objectSpread2({}, table), {}, { unsupported: "a table cell given less width than a line of its text that runs up or down" });
if (tooLong.some((cell) => content.get(cell).hyphenated)) return _objectSpread2(_objectSpread2({}, table), {}, { unsupported: "a word Word may hyphenate, longer than its cell" });
- if (table.marginsBeside === true) return _objectSpread2(_objectSpread2({}, table), {}, { unsupported: "a table widened for a long word, or its rows evened out, in a document in compatibility mode" });
}
const { columns, unsettled } = widen ? sizeGivenColumns(table, content) : sizeColumns(table, content);
const total = sum$1(columns.map(({ width }) => width));
+ if (widen && table.marginsBeside === true && (widen.uneven || spaced || widen.share !== void 0 || total > available - indent + SAME)) return _objectSpread2(_objectSpread2({}, table), {}, { unsupported: "a table widened for a long word past the room for it, or with its rows evened out, in a document in compatibility mode" });
const tableWidth = fit !== null && fit !== void 0 ? fit : widen;
const borders = table.marginsBeside === true ? 0 : (((_table$borderLeft = table.borderLeft) !== null && _table$borderLeft !== void 0 ? _table$borderLeft : 0) + ((_table$borderRight = table.borderRight) !== null && _table$borderRight !== void 0 ? _table$borderRight : 0)) / 2;
const beside = table.marginsBeside === true ? outerMargins(table) : 0;
@@ -35377,11 +35373,11 @@ var docxLayout = (function(exports) {
const floating = readFloating(drawing["wp:anchor"]);
return typeof floating === "string" ? floating : floatingItem(floating, reader);
};
- var OLDER_VML = "a VML drawing in a document in compatibility mode 12 or 11";
+ var OLDER_VML = "a VML drawing other than a text box in the line, in a document in compatibility mode 12 or 11";
var DEFAULT_VML_SIZE = 50;
var VML_PICTURE = "a VML picture";
- /** Whether the document is in Word 2007's or 2003's compatibility mode, where VML drawings aren't laid out as Word does */
- var olderVml = ({ compatibilityMode }) => compatibilityMode !== void 0 && compatibilityMode < 14;
+ /** Whether the document is in Word 2007's or 2003's compatibility mode, where Word lays out VML drawings otherwise */
+ var olderVml = ({ compatibilityMode }) => compatibilityMode !== void 0 && compatibilityMode < WORD_2010_MODE;
/**
* Reads a VML drawing (`w:pict`), as Word lays it out (scripts/layout-probes/word-vml.ts and
* scripts/layout-probes/stops2/word-stops-vml.ts). A shape in the line is a box of its size, with its run's font, standing
@@ -35434,7 +35430,7 @@ var docxLayout = (function(exports) {
height,
font
}]) : reason;
- if (olderVml(reader)) return OLDER_VML;
+ if (olderVml(reader) && (shape.text === void 0 || reader.inHeader || reader.inTextBox)) return OLDER_VML;
if (reader.inTextBox) return sized("a VML drawing in the line of a text box");
if (shape.text !== void 0) return readTextBox(shape, width, height, outline, font, reader);
if (picture) return sized(VML_PICTURE);
@@ -35523,7 +35519,7 @@ var docxLayout = (function(exports) {
if (typeof blocks === "string") return blocks;
const { weight, drawn } = outline;
const { left, right, top, bottom } = insets;
- const outside = drawn ? weight : 0;
+ const outside = drawn && !olderVml(reader) ? weight : 0;
const extra = fits && weight === .72 ? 0 : TEXT_BOX_EXTRA;
return [...markersIn(blocks).map((name) => ({
type: "marker",
@@ -35764,7 +35760,7 @@ var docxLayout = (function(exports) {
readRunFormat(properties, styles.themeFonts)
]);
const size = (_formatted$size = formatted.size) !== null && _formatted$size !== void 0 ? _formatted$size : 10;
- const format = isTwoInOne(childrenOf(properties)) ? _objectSpread2(_objectSpread2({}, formatted), {}, { size: size / 2 }) : formatted;
+ const format = withFeaturesOf(isTwoInOne(childrenOf(properties)) ? _objectSpread2(_objectSpread2({}, formatted), {}, { size: size / 2 }) : formatted, reader);
const font = fontOf(format);
const down = reader.down === true;
const unsupportedFormat = (_unsupportedFormatOf = unsupportedFormatOf(childrenOf(properties), children, size, format, down)) !== null && _unsupportedFormatOf !== void 0 ? _unsupportedFormatOf : format.hidden ? void 0 : unknownRunFormatting(format);
@@ -36184,7 +36180,7 @@ var docxLayout = (function(exports) {
var _list$starts$get;
return current[at] === void 0 && !started.includes(`${id} ${at}`) && ((_list$starts$get = list.starts.get(at)) !== null && _list$starts$get !== void 0 ? _list$starts$get : levels[at].start) !== levels[at].start;
};
- const font = fontOf(combine([markRun, level.run]));
+ const font = fontOf(withFeaturesOf(combine([markRun, level.run]), reader));
const unsupported = (_level$unsupported = level.unsupported) !== null && _level$unsupported !== void 0 ? _level$unsupported : levels.some((other) => (other === null || other === void 0 ? void 0 : other.alignedBoth) === true) ? "a list number at another level of a list with a level aligned both" : restartedByLeftOut ? "a list number after a paragraph at a level Word leaves out above it" : referred.some((at) => numberAt(at) === void 0) ? "a list number in a format not yet written" : referred.some(ownStart) ? "a list number of a level not counted yet, which its list starts at a number of its own" : font.border !== void 0 ? "a list number with a border" : void 0;
const text = level.text.replace(/%([1-9])/g, (_, digit) => {
var _numberAt;
@@ -36258,26 +36254,32 @@ var docxLayout = (function(exports) {
return current;
};
var ARABIC = new RegExp("\\p{Script=Arabic}", "u");
- var SQUEEZED_ALIGNMENTS = /* @__PURE__ */ new Set([
- "distributed",
- "thaiDistributed",
- "lowKashida"
- ]);
+ /**
+ * A run's formatting as Word draws it in the document's compatibility mode: Word 2007 and 2003 had no OpenType features,
+ * which Word 2010's mode has on only with `enableOpenTypeFeatures`, as Word 2010 writes it, and without it Word draws no
+ * ligatures in modes 14 and 12, whatever a run asks for (`word-stops-compat2-14.docx`, `-12` CN2b)
+ */
+ var withFeaturesOf = (format, { compatibilityMode, openTypeFeatures }) => compatibilityMode !== void 0 && openTypeFeatures !== true && format.ligatures !== void 0 ? _objectSpread2(_objectSpread2({}, format), {}, { ligatures: void 0 }) : format;
/**
* Why a paragraph can't be laid out as Word lays it out in the document's compatibility mode, or with Word 2003's layout
- * of East Asian text (`useFELayout`), when it can't. Word 2010 and before don't squeeze the spaces of a justified line
- * (`word-stops-compat-14.docx` CM1), and whether they squeeze a distributed one, or one justified for Thai or with a low
- * kashida, as Word 2013 does, hasn't been seen. Word 2007 and 2003 broke East Asian text otherwise than Word 2010 and
- * 2013 (CM18), and so does Word 2003's East Asian layout (`word-stops-fe-layout.docx` FE1a, FE1b), in ways not yet
- * followed. Paragraphs without East Asian text it lays out as they are without it (FE1c to FE1f).
+ * of East Asian text (`useFELayout`), when it can't. Word 2010 and before don't squeeze the spaces of a justified line,
+ * nor of a distributed one, or one justified for Thai or with a low kashida (`word-stops-compat-14.docx` CM1,
+ * `word-stops-compat2-14.docx` CN4a to CN4c), which the lines are broken for (see `line-breaking.ts`). Word 2007 and 2003
+ * break East Asian text otherwise than Word 2010 and 2013 (CM18, CN10a to CN10c), and Word 2003's East Asian layout
+ * spaces it apart from the text beside it (`word-stops-fe-layout.docx` FE1a, FE1b): see below. Paragraphs without East
+ * Asian text it lays out as they are without it (FE1c to FE1f).
*/
- var unknownInOlderLayout = (items, alignment, reader) => {
+ var unknownInOlderLayout = (items, reader, autoSpaced) => {
const { compatibilityMode } = reader;
- if (compatibilityMode !== void 0 && SQUEEZED_ALIGNMENTS.has(alignment)) return "a paragraph distributed, or justified for Thai or with a low kashida, in a document in compatibility mode";
- if (compatibilityMode !== void 0 && reader.openTypeFeatures !== true && items.some((item) => item.type === "text" && item.font.ligatures !== void 0)) return "ligatures in a document in compatibility mode that doesn't turn on OpenType features";
- const older = compatibilityMode !== void 0 && compatibilityMode < 14;
- if (!older && reader.feLayout !== true || !items.some((item) => item.type === "text" && [...item.text].some(isEastAsian))) return;
- return older ? "East Asian text in a document in compatibility mode 12 or 11" : "East Asian text in a document that lays it out as Word 2003 did (useFELayout)";
+ const older = compatibilityMode !== void 0 && compatibilityMode < WORD_2010_MODE;
+ const texts = items.filter((item) => item.type === "text");
+ if (!texts.some((item) => [...item.text].some(isEastAsian)) || !older && reader.feLayout !== true) return;
+ if (!older) {
+ const characters = [...texts.map(({ text }) => text).join("")];
+ const beside = characters.some((character, at) => at > 0 && isEastAsian(character) !== isEastAsian(characters[at - 1]) && !/\s/u.test(character + characters[at - 1]));
+ return autoSpaced && beside ? "East Asian text beside other text, which Word spaces apart, in a document that lays it out as Word 2003 did (useFELayout)" : void 0;
+ }
+ return texts.some((item) => kinsokuLanguageOf(item.language) !== void 0 || [...item.text].some((character) => character.codePointAt(0) > LAST_ASCII && !isEastAsian(character))) ? "East Asian text in an East Asian language, or beside characters past ASCII, in a document in compatibility mode 12 or 11" : void 0;
};
var POINTS_PER_LINE = 12;
var HUNDREDTHS = 100;
@@ -36458,7 +36460,9 @@ var docxLayout = (function(exports) {
const read = withEquations(withFitted(readInline(children, paragraphRun, reader), reader), list.items.length > 0, reader);
const guessed = typeof read === "string" ? void 0 : read.map(guessOf).find((reason) => reason !== void 0);
const items = typeof read === "string" ? read : read.filter((item) => guessOf(item) === void 0);
- const combined = combine(formats);
+ const ownFormat = combine(formats);
+ const division = readDivision(properties, ownFormat, reader);
+ const combined = division === void 0 ? ownFormat : combine([ownFormat, division.format]);
const own = typeof items === "string" ? [] : items;
const content = typeof items === "string" ? [] : [...list.items, ...items];
const markFont = fontOf(markRun);
@@ -36487,14 +36491,121 @@ var docxLayout = (function(exports) {
const tabStops = tabStopsOf(formats);
const otherDecimalSymbol = reader.decimalSymbol !== void 0 && reader.decimalSymbol !== "." && tabStops.some(({ alignment }) => alignment === "decimal");
const frame = readFrameOf(properties, styleChain(styles, style, "paragraph"), reader);
- const unsupported = (_ref4 = (_ref5 = (_ref6 = (_ref7 = (_list$unsupported = list.unsupported) !== null && _list$unsupported !== void 0 ? _list$unsupported : ownCells) !== null && _ref7 !== void 0 ? _ref7 : unknownEastAsianRules(reader.eastAsianRules, own, combined.alignment)) !== null && _ref6 !== void 0 ? _ref6 : joinedAcrossRuns(own) ? "Arabic letters joined across runs" : void 0) !== null && _ref5 !== void 0 ? _ref5 : reader.down === true ? unknownDownOf(own, tabStops) : void 0) !== null && _ref4 !== void 0 ? _ref4 : typeof frame === "string" ? frame : otherDecimalSymbol ? "a decimal tab stop in a document whose decimal symbol isn't a full stop" : find(properties, "w:divId") !== void 0 ? "a paragraph in an HTML division" : combined.alignment === "mediumKashida" || combined.alignment === "highKashida" ? "a paragraph justified for Arabic with a medium or high kashida" : forThaiOrArabic && typeof items !== "string" && items.some((item) => item.type === "text" && ARABIC.test(item.text)) ? "Arabic text justified for Thai or with a kashida" : (_ref8 = (_ref9 = (_unknownInOlderLayout = unknownInOlderLayout(content, combined.alignment, reader)) !== null && _unknownInOlderLayout !== void 0 ? _unknownInOlderLayout : unjoinedSpacing) !== null && _ref9 !== void 0 ? _ref9 : typeof format === "string" ? format : void 0) !== null && _ref8 !== void 0 ? _ref8 : typeof borders === "string" ? borders : void 0;
- return _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({
+ const unsupported = (_ref4 = (_ref5 = (_ref6 = (_ref7 = (_list$unsupported = list.unsupported) !== null && _list$unsupported !== void 0 ? _list$unsupported : ownCells) !== null && _ref7 !== void 0 ? _ref7 : unknownEastAsianRules(reader.eastAsianRules, own, combined.alignment)) !== null && _ref6 !== void 0 ? _ref6 : joinedAcrossRuns(own) ? "Arabic letters joined across runs" : void 0) !== null && _ref5 !== void 0 ? _ref5 : reader.down === true ? unknownDownOf(own, tabStops) : void 0) !== null && _ref4 !== void 0 ? _ref4 : typeof frame === "string" ? frame : otherDecimalSymbol ? "a decimal tab stop in a document whose decimal symbol isn't a full stop" : (division === null || division === void 0 ? void 0 : division.unsupported) !== void 0 ? division.unsupported : combined.alignment === "mediumKashida" || combined.alignment === "highKashida" ? "a paragraph justified for Arabic with a medium or high kashida" : forThaiOrArabic && typeof items !== "string" && items.some((item) => item.type === "text" && ARABIC.test(item.text)) ? "Arabic text justified for Thai or with a kashida" : (_ref8 = (_ref9 = (_unknownInOlderLayout = unknownInOlderLayout(content, reader, onOff(properties, "w:autoSpaceDE") !== false || onOff(properties, "w:autoSpaceDN") !== false)) !== null && _unknownInOlderLayout !== void 0 ? _unknownInOlderLayout : unjoinedSpacing) !== null && _ref9 !== void 0 ? _ref9 : typeof format === "string" ? format : void 0) !== null && _ref8 !== void 0 ? _ref8 : typeof borders === "string" ? borders : void 0;
+ return _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({
type: "paragraph",
items: content,
format: _objectSpread2(_objectSpread2({}, typeof format === "string" ? combined : format), joined.length === 0 ? {} : { lineSpacingFrom: _objectSpread2({ marker: JOINED_SPACING_MARKER }, withoutUndefined({ lineSpacing: joinedSpacing })) }),
tabStops,
markFont
- }, unsupported === void 0 && typeof items !== "string" && children.some((child) => isObject(child) && LEFT_OUT in child) ? { hidden: true } : {}), list.list ? { list: list.list } : {}), list.alignment ? { numberAlignment: list.alignment } : {}), typeof borders === "object" ? { borders } : {}), paragraphGrid !== void 0 && Object.keys(paragraphGrid).length > 0 ? { grid: paragraphGrid } : {}), typeof frame === "object" ? { frame } : {}), {}, { style }, headingLevel === void 0 ? {} : { heading: _objectSpread2({ level: Number(headingLevel) }, withoutUndefined({ chapter: list.from === "style" ? list.chapter : void 0 })) }), typeof items === "string" || guessed || unsupported ? { unsupported: typeof items === "string" ? items : guessed !== null && guessed !== void 0 ? guessed : unsupported } : {});
+ }, unsupported === void 0 && typeof items !== "string" && children.some((child) => isObject(child) && LEFT_OUT in child) ? { hidden: true } : {}), list.list ? { list: list.list } : {}), list.alignment ? { numberAlignment: list.alignment } : {}), typeof borders === "object" ? { borders } : {}), paragraphGrid !== void 0 && Object.keys(paragraphGrid).length > 0 ? { grid: paragraphGrid } : {}), typeof frame === "object" ? { frame } : {}), (division === null || division === void 0 ? void 0 : division.division) === void 0 ? {} : {
+ division: division.division,
+ unknownAtTop: "a paragraph in an HTML division at the top of a page or column"
+ }), {}, { style }, headingLevel === void 0 ? {} : { heading: _objectSpread2({ level: Number(headingLevel) }, withoutUndefined({ chapter: list.from === "style" ? list.chapter : void 0 })) }), typeof items === "string" || guessed || unsupported ? { unsupported: typeof items === "string" ? items : guessed !== null && guessed !== void 0 ? guessed : unsupported } : {});
+ };
+ /**
+ * The divisions of a web page in a document's web settings (`w:divs`), by their ids, each with the properties of those it
+ * is in, the outermost first
+ */
+ var divisionsIn = (divisions, outer = []) => divisions.filter((child) => "w:div" in child).flatMap((division) => {
+ const chain = [...outer, childrenOf(division["w:div"])];
+ return [[String(attributesOf(division["w:div"])["w:id"]), chain], ...divisionsIn(childrenOf(find(chain[chain.length - 1], "w:divsChild")), chain)];
+ });
+ /**
+ * The division of a web page a paragraph is in (`w:divId`), as Word lays it out, or why it can't be laid out. Word lays out
+ * a paragraph in a division indented by the margins left and right of the division and of the divisions it is in, added
+ * up, with the division's borders as the paragraph's own, outside its indents, and a division's paragraphs together in
+ * one box, with its margin above the box and below it as the space before its first paragraph and after its last: 720
+ * twips in on each side, and 230 above and below three paragraphs, a margin of 120, a border of 30 and its space of 80
+ * (`word-stops-divisions.docx` DV2a, DV2b, `word-stops-pages.docx` DV1a). A division in another with the same margins
+ * above and below has them once (DV2d). With the paragraph's own space before or after it, the division's borders and
+ * margins above and below aren't laid out that way (DV2c), and its own indents or borders, a division in another with
+ * borders or other margins, a quotation or a page's body, and a division in a table cell, a note, a header, a footer or a
+ * text box, haven't been seen.
+ */
+ var readDivision = (properties, own, reader) => {
+ var _reader$divisions;
+ const element = find(properties, "w:divId");
+ if (element === void 0) return;
+ const id = String(attributesOf(element)["w:val"]);
+ const chain = (_reader$divisions = reader.divisions) === null || _reader$divisions === void 0 ? void 0 : _reader$divisions.get(id);
+ if (chain === void 0) return {
+ format: {},
+ unsupported: "a paragraph in an HTML division the document's web settings don't have"
+ };
+ const margin = (name) => chain.map((division) => {
+ var _numberOf4;
+ return (_numberOf4 = numberOf(valueOf(division, name))) !== null && _numberOf4 !== void 0 ? _numberOf4 : 0;
+ });
+ const [above, below] = ["w:marTop", "w:marBottom"].map((name) => new Set(margin(name)));
+ const borders = chain.flatMap((division) => {
+ const border = find(division, "w:divBdr");
+ return border === void 0 ? [] : [border];
+ });
+ const spaced = [
+ own.spaceBefore,
+ own.spaceAfter,
+ own.spaceBeforeLines,
+ own.spaceAfterLines
+ ].some((space) => (space !== null && space !== void 0 ? space : 0) !== 0);
+ const indented = [
+ own.indentLeft,
+ own.indentRight,
+ own.firstLineIndent,
+ own.indentLeftChars,
+ own.indentRightChars,
+ own.firstLineChars
+ ];
+ const bordered = [
+ own.borderTop,
+ own.borderBottom,
+ own.borderLeft,
+ own.borderRight,
+ own.borderBetween,
+ own.borderBar
+ ];
+ const unsupported = reader.inCell || reader.inNote || reader.inHeader || reader.inTextBox ? "a paragraph in an HTML division in a table cell, note, header, footer or text box" : chain.some((division) => onOff(division, "w:blockQuote") === true || onOff(division, "w:bodyDiv") === true) ? "an HTML division that is a quotation or a page's body" : above.size > 1 || below.size > 1 || chain.length > 1 && borders.length > 0 ? "an HTML division in another, with borders, or other margins above or below" : spaced || own.autoSpaceBefore === true || own.autoSpaceAfter === true ? "a paragraph in an HTML division with space before or after it" : indented.some((indent) => (indent !== null && indent !== void 0 ? indent : 0) !== 0) || bordered.some((border) => border !== void 0) ? "a paragraph in an HTML division with indents or borders of its own" : void 0;
+ const sum = (name) => margin(name).reduce((total, length) => total + length, 0);
+ return _objectSpread2({
+ format: readParagraphFormat([{ "w:ind": { _attr: {
+ "w:left": sum("w:marLeft"),
+ "w:right": sum("w:marRight")
+ } } }, ...borders.map((border) => ({ "w:pBdr": border }))]),
+ division: {
+ id,
+ above: Math.max(...above) / 20,
+ below: Math.max(...below) / 20
+ }
+ }, unsupported === void 0 ? {} : { unsupported });
+ };
+ /**
+ * The body's blocks with the margins of the divisions of a web page their paragraphs are in as space before the first
+ * paragraph of each division and after its last (see `readDivision`). Space after the paragraph before a division, or
+ * before the one after it, or a division next to another, haven't been seen
+ */
+ var withDivisions = (blocks) => {
+ const divisionOf = (at) => {
+ var _blocks$at;
+ const block = (_blocks$at = blocks[at]) === null || _blocks$at === void 0 ? void 0 : _blocks$at.block;
+ return (block === null || block === void 0 ? void 0 : block.type) === "paragraph" ? block.division : void 0;
+ };
+ return blocks.map((placed, at) => {
+ var _blocks, _blocks2, _previous$format$spac, _next$format$spaceBef;
+ const { block } = placed;
+ if (block.type !== "paragraph" || block.division === void 0) return placed;
+ const { id, above, below } = block.division;
+ const [before, after] = [at - 1, at + 1].map(divisionOf);
+ const [previous, next] = [(_blocks = blocks[at - 1]) === null || _blocks === void 0 ? void 0 : _blocks.block, (_blocks2 = blocks[at + 1]) === null || _blocks2 === void 0 ? void 0 : _blocks2.block];
+ const first = (before === null || before === void 0 ? void 0 : before.id) !== id;
+ const last = (after === null || after === void 0 ? void 0 : after.id) !== id;
+ const spacedBefore = (previous === null || previous === void 0 ? void 0 : previous.type) === "paragraph" && (((_previous$format$spac = previous.format.spaceAfter) !== null && _previous$format$spac !== void 0 ? _previous$format$spac : 0) > 0 || previous.format.autoSpaceAfter === true);
+ const spacedAfter = (next === null || next === void 0 ? void 0 : next.type) === "paragraph" && (((_next$format$spaceBef = next.format.spaceBefore) !== null && _next$format$spaceBef !== void 0 ? _next$format$spaceBef : 0) > 0 || next.format.autoSpaceBefore === true);
+ const unsupported = first && before !== void 0 || last && after !== void 0 ? "an HTML division next to another" : first && spacedBefore || last && spacedAfter ? "an HTML division next to a paragraph with space before or after it" : void 0;
+ return _objectSpread2(_objectSpread2({}, placed), {}, { block: _objectSpread2(_objectSpread2({}, block), {}, { format: _objectSpread2(_objectSpread2({}, block.format), {}, {
+ spaceBefore: first ? above : 0,
+ spaceAfter: last ? below : 0
+ }) }, block.unsupported === void 0 && unsupported !== void 0 ? { unsupported } : {}) });
+ });
};
/** Why a cell's text direction (`w:textDirection`) isn't followed, when it is one the schema doesn't have */
var unsupportedCellOf = (properties) => {
@@ -36684,7 +36795,7 @@ var docxLayout = (function(exports) {
* bands by each row's place among all the rows, the deleted ones too (MK14j to MK14l).
*/
var readTable = (element, reader) => {
- var _twips2, _reader$grid, _readTableLook, _kept$0$spacing, _kept$, _ref16, _ref17, _ref18, _ref19, _ref20, _ref21, _ref22, _ref23, _ref24, _ref25, _ref26, _ref27, _ref28, _ref29, _ref30, _withoutGuess$unsuppo, _read$find2, _givenWidth$share, _blocks$find, _read$0$cells, _read$, _roomOf, _roomOf2;
+ var _twips2, _reader$grid, _readTableLook, _kept$0$spacing, _kept$, _ref16, _ref17, _ref18, _ref19, _ref20, _ref21, _ref22, _ref23, _ref24, _ref25, _ref26, _ref27, _ref28, _ref29, _ref30, _ref31, _withoutGuess$unsuppo, _read$find2, _givenWidth$share, _blocks$find, _read$0$cells, _read$, _roomOf, _roomOf2;
const children = contentOf$3(element).filter(isObject);
const properties = childrenOf(find(children, "w:tblPr"));
const style = valueOf(properties, "w:tblStyle");
@@ -36766,7 +36877,7 @@ var docxLayout = (function(exports) {
}, void 0);
const gridWidth = (from, to) => grid.slice(from, to).reduce((total, value) => total + value, 0);
const read = rows.map(({ element: row, bookmarks: rowBookmarks }, rowIndex) => {
- var _formatsOf$height, _numberOf4, _ref13, _onOff2;
+ var _formatsOf$height, _numberOf5, _ref13, _onOff2;
const rowChildren = contentOf$3(row).filter(isObject);
const rowProperties = childrenOf(find(rowChildren, "w:trPr"));
const rowParts = unwrap(rowChildren);
@@ -36784,7 +36895,7 @@ var docxLayout = (function(exports) {
}).height) !== null && _formatsOf$height !== void 0 ? _formatsOf$height : {} : attributesOf(ownHeight);
const height = twips(heightAttributes["w:val"]);
const { "w:hRule": rule } = heightAttributes;
- const skipped = (_numberOf4 = numberOf(attributesOf(find(rowProperties, "w:gridBefore"))["w:val"])) !== null && _numberOf4 !== void 0 ? _numberOf4 : 0;
+ const skipped = (_numberOf5 = numberOf(attributesOf(find(rowProperties, "w:gridBefore"))["w:val"])) !== null && _numberOf5 !== void 0 ? _numberOf5 : 0;
const { "w:w": beforeValue, "w:type": beforeType = "dxa" } = attributesOf(find(rowProperties, "w:wBefore"));
const widthBefore = skipped > 0 && beforeType === "dxa" ? twips(beforeValue) : void 0;
const ownSpacing = find(rowProperties, "w:tblCellSpacing");
@@ -36814,8 +36925,8 @@ var docxLayout = (function(exports) {
const cellChildren = contentOf$3(cell).filter(isObject);
const cellProperties = childrenOf(find(cellChildren, "w:tcPr"));
const spanOf = (given) => {
- var _numberOf5;
- return (_numberOf5 = numberOf(attributesOf(find(given, "w:gridSpan"))["w:val"])) !== null && _numberOf5 !== void 0 ? _numberOf5 : 1;
+ var _numberOf6;
+ return (_numberOf6 = numberOf(attributesOf(find(given, "w:gridSpan"))["w:val"])) !== null && _numberOf6 !== void 0 ? _numberOf6 : 1;
};
const acrossProperties = across.map((merged) => childrenOf(find(contentOf$3(merged.element).filter(isObject), "w:tcPr")));
const span = [cellProperties, ...acrossProperties].reduce((total, given) => total + spanOf(given), 0);
@@ -37001,21 +37112,34 @@ var docxLayout = (function(exports) {
const floatElement = reader.inNote === true && !reader.inCell && reader.inTextBox !== true ? void 0 : find(properties, "w:tblpPr");
const float = floatElement === void 0 ? void 0 : readTableFloat(floatElement, find(properties, "w:tblOverlap"));
const older = reader.compatibilityMode !== void 0;
- const marginsBeside = older && sized && givenWidth.width === void 0;
+ const marginsBeside = older && sized && givenWidth.width === void 0 && reader.inCell !== true;
const verticalUnsupported = fits && (float !== void 0 || reader.inSizedTable === true) && tableCells.some((cell) => cell.vertical && !isVerticalWidthKnown(cell)) ? "text that runs up or down a cell of a table sized to its text, in a table cell or that text flows around" : void 0;
- const unsupported = (_ref16 = (_ref17 = (_ref18 = (_ref19 = (_ref20 = (_ref21 = (_ref22 = (_ref23 = (_ref24 = (_ref25 = (_ref26 = (_ref27 = (_ref28 = (_ref29 = (_ref30 = (_withoutGuess$unsuppo = withoutGuess === null || withoutGuess === void 0 ? void 0 : withoutGuess.unsupported) !== null && _withoutGuess$unsuppo !== void 0 ? _withoutGuess$unsuppo : reader.down === true ? "a table on text that runs down the page" : void 0) !== null && _ref30 !== void 0 ? _ref30 : float !== void 0 && (reader.inCell || reader.inHeader) ? "a table that text flows around in a table cell, header or footer" : void 0) !== null && _ref29 !== void 0 ? _ref29 : float !== void 0 && older ? "a table that text flows around in a document in compatibility mode" : void 0) !== null && _ref28 !== void 0 ? _ref28 : marginsBeside && fits && (reader.inCell === true || indent !== 0 || givenWidth.share !== void 0) ? "a table sized to its text in a table cell, indented or as a share of the width, in a document in compatibility mode" : void 0) !== null && _ref27 !== void 0 ? _ref27 : typeof float === "string" ? float : void 0) !== null && _ref26 !== void 0 ? _ref26 : parts.some((part) => "w:sdt" in part) ? BOUND_CONTROL : void 0) !== null && _ref25 !== void 0 ? _ref25 : (_read$find2 = read.find((row) => row.unsupported !== void 0)) === null || _read$find2 === void 0 ? void 0 : _read$find2.unsupported) !== null && _ref24 !== void 0 ? _ref24 : unmerged) !== null && _ref23 !== void 0 ? _ref23 : fits ? unfitted : unequal && !evened ? "a table whose rows give a column different widths" : void 0) !== null && _ref22 !== void 0 ? _ref22 : verticalUnsupported) !== null && _ref21 !== void 0 ? _ref21 : spacingUnsupported) !== null && _ref20 !== void 0 ? _ref20 : typeof geometry === "string" ? geometry : void 0) !== null && _ref19 !== void 0 ? _ref19 : indent === void 0 ? "a table indent of a type not yet followed" : void 0) !== null && _ref18 !== void 0 ? _ref18 : ((_givenWidth$share = givenWidth.share) !== null && _givenWidth$share !== void 0 ? _givenWidth$share : 0) > 1 ? "a table whose width is a share of more than the width it is in" : void 0) !== null && _ref17 !== void 0 ? _ref17 : styleUnsupported) !== null && _ref16 !== void 0 ? _ref16 : (_blocks$find = blocks.find((block) => block.unsupported !== void 0)) === null || _blocks$find === void 0 ? void 0 : _blocks$find.unsupported;
+ const unsupported = (_ref16 = (_ref17 = (_ref18 = (_ref19 = (_ref20 = (_ref21 = (_ref22 = (_ref23 = (_ref24 = (_ref25 = (_ref26 = (_ref27 = (_ref28 = (_ref29 = (_ref30 = (_ref31 = (_withoutGuess$unsuppo = withoutGuess === null || withoutGuess === void 0 ? void 0 : withoutGuess.unsupported) !== null && _withoutGuess$unsuppo !== void 0 ? _withoutGuess$unsuppo : reader.down === true ? "a table on text that runs down the page" : void 0) !== null && _ref31 !== void 0 ? _ref31 : float !== void 0 && (reader.inCell || reader.inHeader) ? "a table that text flows around in a table cell, header or footer" : void 0) !== null && _ref30 !== void 0 ? _ref30 : typeof float === "object" && older && (marginsBeside || float.horizontal.align !== void 0 || float.distances.left === 0 || float.distances.right === 0) ? "a table that text flows around, sized to its text, lined up across the page or with no distance from the text beside it, in a document in compatibility mode" : void 0) !== null && _ref29 !== void 0 ? _ref29 : marginsBeside && fits && givenWidth.share !== void 0 ? "a table sized to its text as a share of the width, in a document in compatibility mode" : void 0) !== null && _ref28 !== void 0 ? _ref28 : older && sized && fits && givenWidth.width === void 0 && reader.inCell === true && (indent !== 0 || givenWidth.share !== void 0) ? "a table sized to its text in a table cell, indented or as a share of the width, in a document in compatibility mode" : void 0) !== null && _ref27 !== void 0 ? _ref27 : typeof float === "string" ? float : void 0) !== null && _ref26 !== void 0 ? _ref26 : parts.some((part) => "w:sdt" in part) ? BOUND_CONTROL : void 0) !== null && _ref25 !== void 0 ? _ref25 : (_read$find2 = read.find((row) => row.unsupported !== void 0)) === null || _read$find2 === void 0 ? void 0 : _read$find2.unsupported) !== null && _ref24 !== void 0 ? _ref24 : unmerged) !== null && _ref23 !== void 0 ? _ref23 : fits ? unfitted : unequal && !evened ? "a table whose rows give a column different widths" : void 0) !== null && _ref22 !== void 0 ? _ref22 : verticalUnsupported) !== null && _ref21 !== void 0 ? _ref21 : spacingUnsupported) !== null && _ref20 !== void 0 ? _ref20 : typeof geometry === "string" ? geometry : void 0) !== null && _ref19 !== void 0 ? _ref19 : indent === void 0 ? "a table indent of a type not yet followed" : void 0) !== null && _ref18 !== void 0 ? _ref18 : ((_givenWidth$share = givenWidth.share) !== null && _givenWidth$share !== void 0 ? _givenWidth$share : 0) > 1 ? "a table whose width is a share of more than the width it is in" : void 0) !== null && _ref17 !== void 0 ? _ref17 : styleUnsupported) !== null && _ref16 !== void 0 ? _ref16 : (_blocks$find = blocks.find((block) => block.unsupported !== void 0)) === null || _blocks$find === void 0 ? void 0 : _blocks$find.unsupported;
const rowWidth = ((_read$0$cells = (_read$ = read[0]) === null || _read$ === void 0 ? void 0 : _read$.cells) !== null && _read$0$cells !== void 0 ? _read$0$cells : []).reduce((total, cell) => {
var _cell$ownWidth;
return total + ((_cell$ownWidth = cell.ownWidth) !== null && _cell$ownWidth !== void 0 ? _cell$ownWidth : 0);
}, 0);
+ const borderLeft = (_roomOf = roomOf(tableBorders.left)) !== null && _roomOf !== void 0 ? _roomOf : 0;
const tableWidth = spaced && givenWidth.width === void 0 && givenWidth.share === void 0 ? { width: rowWidth } : givenWidth;
return _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({
type: "table",
rows: tableRows
}, fits ? { fit: givenWidth } : {}), !fits && (!fixed || spaced || fixedFit) ? { widen: _objectSpread2(_objectSpread2(_objectSpread2({}, tableWidth), evened ? { uneven: true } : {}), fixed && !spaced ? { fixed: true } : {}) } : {}), {}, {
- borderLeft: (_roomOf = roomOf(tableBorders.left)) !== null && _roomOf !== void 0 ? _roomOf : 0,
+ borderLeft,
borderRight: (_roomOf2 = roomOf(tableBorders.right)) !== null && _roomOf2 !== void 0 ? _roomOf2 : 0
- }, indent ? { indent } : {}), spaced ? { cellSpacing: followedSpacing } : {}), deletedRows.length > 0 ? { deletedRows } : {}), typeof float === "object" ? { float } : {}), marginsBeside ? { marginsBeside } : {}), unsupported ? { unsupported } : {}), withoutGuess ? { noGuess: true } : {});
+ }, indent ? { indent } : {}), spaced ? { cellSpacing: followedSpacing } : {}), deletedRows.length > 0 ? { deletedRows } : {}), typeof float === "object" ? { float: older ? textAtPosition(float, tableRows, borderLeft) : float } : {}), marginsBeside ? { marginsBeside } : {}), unsupported ? { unsupported } : {}), withoutGuess ? { noGuess: true } : {});
+ };
+ /**
+ * A table that text flows around placed as Word 2010 and before place it: with its first cell's text, rather than its left
+ * border, where it is placed across the page, its first cell's margin and half its left border to the left of where Word
+ * 2013 places it (`word-stops-compat-14.docx` CM10, `word-stops-compat2-14.docx` CN9: 113 twips, for a margin of 108 and a
+ * border of half a point)
+ */
+ var textAtPosition = (float, rows, borderLeft) => {
+ var _rows$0$cells$0$margi, _rows$;
+ const { horizontal } = float;
+ const shift = ((_rows$0$cells$0$margi = (_rows$ = rows[0]) === null || _rows$ === void 0 || (_rows$ = _rows$.cells[0]) === null || _rows$ === void 0 ? void 0 : _rows$.marginLeft) !== null && _rows$0$cells$0$margi !== void 0 ? _rows$0$cells$0$margi : 0) + borderLeft / 2;
+ return horizontal.offset === void 0 ? float : _objectSpread2(_objectSpread2({}, float), {}, { horizontal: _objectSpread2(_objectSpread2({}, horizontal), {}, { offset: horizontal.offset - shift }) });
};
var TABLE_AXES = {
horzAnchor: {
@@ -37357,9 +37481,9 @@ var docxLayout = (function(exports) {
* it is, in one column: with a break or without, its text is laid out the same
*/
var startsOnItsPage = (section, next) => {
- var _numberOf6;
+ var _numberOf7;
const rest = (properties) => JSON.stringify(childrenOf(properties).filter((child) => nameOf$1(child) !== "w:type"));
- return sectionTypeOf(next) === "continuous" && rest(section) === rest(next) && ((_numberOf6 = numberOf(attributesOf(find(childrenOf(section), "w:cols"))["w:num"])) !== null && _numberOf6 !== void 0 ? _numberOf6 : 1) <= 1;
+ return sectionTypeOf(next) === "continuous" && rest(section) === rest(next) && ((_numberOf7 = numberOf(attributesOf(find(childrenOf(section), "w:cols"))["w:num"])) !== null && _numberOf7 !== void 0 ? _numberOf7 : 1) <= 1;
};
var CONTROL_START = "docx-layout:control-start";
/** The content of a content control or custom XML, unless it is bound to custom XML, which is laid out as it is */
@@ -37700,14 +37824,14 @@ var docxLayout = (function(exports) {
* the same space between them, unless the section gives each column's width.
*/
var readColumns = (element, width) => {
- var _numberOf7, _twips8;
+ var _numberOf8, _twips8;
const attributes = attributesOf(element);
const given = childrenOf(element).filter((child) => "w:col" in child);
if (isOff(attributes["w:equalWidth"]) && given.length > 0) return given.map((column) => {
var _twips7;
return (_twips7 = twips(attributesOf(column["w:col"])["w:w"])) !== null && _twips7 !== void 0 ? _twips7 : 0;
});
- const count = Math.max(1, (_numberOf7 = numberOf(attributes["w:num"])) !== null && _numberOf7 !== void 0 ? _numberOf7 : 1);
+ const count = Math.max(1, (_numberOf8 = numberOf(attributes["w:num"])) !== null && _numberOf8 !== void 0 ? _numberOf8 : 1);
const space = (_twips8 = twips(attributes["w:space"])) !== null && _twips8 !== void 0 ? _twips8 : DEFAULT_COLUMN_SPACE;
return Array.from({ length: count }, () => (width - space * (count - 1)) / count);
};
@@ -37739,7 +37863,7 @@ var docxLayout = (function(exports) {
* document's grid of no type (`default`) is no grid, whatever its pitch.
*/
var readGrid = (element, normalSize, { gutterAtTop }) => {
- var _numberOf8, _twips13, _twips14, _twips15;
+ var _numberOf9, _twips13, _twips14, _twips15;
const properties = childrenOf(element);
const attributes = attributesOf(find(properties, "w:docGrid"));
const type = attributes["w:type"];
@@ -37748,7 +37872,7 @@ var docxLayout = (function(exports) {
const linePitch = pitch !== void 0 && pitch > 0 ? pitch : void 0;
if (type === "lines") return linePitch === void 0 ? void 0 : { linePitch };
if (linePitch === void 0) return "a document grid of characters without the pitch of its lines";
- const space = ((_numberOf8 = numberOf(attributes["w:charSpace"])) !== null && _numberOf8 !== void 0 ? _numberOf8 : 0) / CHARACTER_SPACE_UNITS;
+ const space = ((_numberOf9 = numberOf(attributes["w:charSpace"])) !== null && _numberOf9 !== void 0 ? _numberOf9 : 0) / CHARACTER_SPACE_UNITS;
if (type === "linesAndChars") return _objectSpread2({ linePitch }, space === 0 ? {} : { characterSpace: space });
const margins = attributesOf(find(properties, "w:pgMar"));
const columns = downOf(properties) === void 0 ? readColumns(find(properties, "w:cols"), textWidthOf(properties, gutterAtTop)) : [((_twips13 = twips(attributesOf(find(properties, "w:pgSz"))["w:h"])) !== null && _twips13 !== void 0 ? _twips13 : DEFAULT_SECTION.pageHeight) - Math.abs((_twips14 = twips(margins["w:top"])) !== null && _twips14 !== void 0 ? _twips14 : DEFAULT_SECTION.marginTop) - Math.abs((_twips15 = twips(margins["w:bottom"])) !== null && _twips15 !== void 0 ? _twips15 : DEFAULT_SECTION.marginBottom)];
@@ -37855,18 +37979,18 @@ var docxLayout = (function(exports) {
* apart.
*/
var readLevel = (element, styles) => {
- var _valueOf9, _numberOf9, _valueOf10, _stringOf3, _valueOf11, _numberOf10;
+ var _valueOf9, _numberOf10, _valueOf10, _stringOf3, _valueOf11, _numberOf11;
const children = childrenOf(element);
const jc = (_valueOf9 = valueOf(children, "w:lvlJc")) !== null && _valueOf9 !== void 0 ? _valueOf9 : "left";
const restart = numberOf(attributesOf(find(children, "w:lvlRestart"))["w:val"]);
const unsupported = !(jc in NUMBER_ALIGNMENTS) && jc !== "both" ? "a list number aligned in a way not yet followed" : find(children, "w:lvlPicBulletId") !== void 0 ? "a list whose bullets are pictures" : isOn(attributesOf(find(children, "w:legacy"))["w:legacy"]) ? "a list numbered as Word 6 numbered lists" : void 0;
return {
- index: (_numberOf9 = numberOf(attributesOf(element)["w:ilvl"])) !== null && _numberOf9 !== void 0 ? _numberOf9 : 0,
+ index: (_numberOf10 = numberOf(attributesOf(element)["w:ilvl"])) !== null && _numberOf10 !== void 0 ? _numberOf10 : 0,
level: _objectSpread2(_objectSpread2(_objectSpread2({}, withoutUndefined({ style: valueOf(children, "w:pStyle") })), {}, {
format: (_valueOf10 = valueOf(children, "w:numFmt")) !== null && _valueOf10 !== void 0 ? _valueOf10 : "decimal",
text: (_stringOf3 = stringOf(attributesOf(find(children, "w:lvlText"))["w:val"])) !== null && _stringOf3 !== void 0 ? _stringOf3 : "",
suffix: (_valueOf11 = valueOf(children, "w:suff")) !== null && _valueOf11 !== void 0 ? _valueOf11 : "tab",
- start: (_numberOf10 = numberOf(attributesOf(find(children, "w:start"))["w:val"])) !== null && _numberOf10 !== void 0 ? _numberOf10 : 0
+ start: (_numberOf11 = numberOf(attributesOf(find(children, "w:start"))["w:val"])) !== null && _numberOf11 !== void 0 ? _numberOf11 : 0
}, withoutUndefined({
alignment: NUMBER_ALIGNMENTS[jc],
restart,
@@ -37954,9 +38078,9 @@ var docxLayout = (function(exports) {
level
})), ...own]);
const starts = new Map(overrides.flatMap(({ index, children: given }) => {
- var _numberOf11;
+ var _numberOf12;
const level = childrenOf(find(given, "w:lvl"));
- const start = (_numberOf11 = numberOf(attributesOf(find(given, "w:startOverride"))["w:val"])) !== null && _numberOf11 !== void 0 ? _numberOf11 : numberOf(attributesOf(find(level, "w:start"))["w:val"]);
+ const start = (_numberOf12 = numberOf(attributesOf(find(given, "w:startOverride"))["w:val"])) !== null && _numberOf12 !== void 0 ? _numberOf12 : numberOf(attributesOf(find(level, "w:start"))["w:val"]);
return start === void 0 ? [] : [[index, start]];
}));
const list = _objectSpread2({
@@ -37979,6 +38103,8 @@ var docxLayout = (function(exports) {
14
]);
var WORD_2007_MODE = 12;
+ var WORD_2010_MODE = 14;
+ var LAST_ASCII = 127;
var WORD_SETTINGS = "http://schemas.microsoft.com/office/word";
var FOLLOWED_COMPATIBILITY = /* @__PURE__ */ new Set([
"w:doNotUseHTMLParagraphAutoSpacing",
@@ -38081,8 +38207,8 @@ var docxLayout = (function(exports) {
* 15 for Word 2013 and later. Word's own setting, as another application's may have the same name
*/
var compatibilityModeOf = (settings) => {
- var _numberOf12, _wordSettingsOf$find;
- return (_numberOf12 = numberOf((_wordSettingsOf$find = wordSettingsOf(childrenOf(find(settings, "w:compat"))).find(({ "w:name": setting }) => setting === "compatibilityMode")) === null || _wordSettingsOf$find === void 0 ? void 0 : _wordSettingsOf$find["w:val"])) !== null && _numberOf12 !== void 0 ? _numberOf12 : WORD_2007_MODE;
+ var _numberOf13, _wordSettingsOf$find;
+ return (_numberOf13 = numberOf((_wordSettingsOf$find = wordSettingsOf(childrenOf(find(settings, "w:compat"))).find(({ "w:name": setting }) => setting === "compatibilityMode")) === null || _wordSettingsOf$find === void 0 ? void 0 : _wordSettingsOf$find["w:val"])) !== null && _numberOf13 !== void 0 ? _numberOf13 : WORD_2007_MODE;
};
/** The compatibility mode a document is laid out in, when it is one of Word 2010's, 2007's or 2003's */
var olderModeOf = (settings) => {
@@ -38155,8 +38281,8 @@ var docxLayout = (function(exports) {
const on = (name) => find(maths, name) !== void 0 && !isOff(valueIn(name));
if (on("m:smallFrac") && !off("m:dispDef")) return { maths: "an equation in a document whose maths settings make fractions small" };
const given = (name) => {
- var _numberOf13;
- return ((_numberOf13 = numberOf(valueIn(name))) !== null && _numberOf13 !== void 0 ? _numberOf13 : 0) !== 0;
+ var _numberOf14;
+ return ((_numberOf14 = numberOf(valueIn(name))) !== null && _numberOf14 !== void 0 ? _numberOf14 : 0) !== 0;
};
return _objectSpread2(_objectSpread2({}, given("m:lMargin") || given("m:rMargin") ? { displayedMaths: "an equation displayed in a document whose maths settings give displayed equations margins" } : {}), {}, { limits: {
sums: valueIn("m:naryLim") === "subSup" ? "subSup" : "undOvr",
@@ -38218,17 +38344,18 @@ var docxLayout = (function(exports) {
const breakRules = _objectSpread2(_objectSpread2({}, Object.keys(lists).length > 0 ? { lists } : {}), onOff(settings, "w:strictFirstAndLastChars") === true ? { strict: true } : {});
const mode = compatibilityModeOf(settings);
const olderMode = olderModeOf(settings);
+ const rules = olderMode !== void 0 && olderMode < WORD_2010_MODE ? _objectSpread2(_objectSpread2({}, breakRules), {}, { ideographs: false }) : breakRules;
const unsupported = (_find4 = [
[mode < CURRENT_COMPATIBILITY_MODE && olderMode === void 0, "a document in a compatibility mode Word hasn't been seen laying out"],
[asksForUnfollowedCompatibility(compatibility, olderMode !== void 0), "a compatibility setting not yet followed"],
- [onOff(settings, "w:bookFoldPrinting") || onOff(settings, "w:bookFoldRevPrinting"), "pages printed as a folded booklet"],
+ [onOff(settings, "w:bookFoldRevPrinting"), "pages printed as a booklet folded the other way round, for text that runs right to left"],
[onOff(settings, "w:linkStyles"), "styles updated from the document's template when Word opens it"]
].find(([applies]) => applies === true)) === null || _find4 === void 0 ? void 0 : _find4[1];
return _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({
defaultTabStop: (_twips21 = twips(attributesOf(find(settings, "w:defaultTabStop"))["w:val"])) !== null && _twips21 !== void 0 ? _twips21 : 36,
evenAndOddHeaders: onOff(settings, "w:evenAndOddHeaders") === true,
addsParagraphSpacing: onOff(compatibility, "w:doNotUseHTMLParagraphAutoSpacing") === true
- }, Object.keys(breakRules).length > 0 ? { breakRules } : {}), onOff(settings, "w:autoHyphenation") === true ? { hyphenation: readHyphenation(settings) } : {}), olderMode === void 0 ? {} : { compatibilityMode: olderMode }), onOff(compatibility, "w:suppressTopSpacing") === true ? { suppressesTopSpacing: true } : {}), unsupported ? { unsupported } : {});
+ }, Object.keys(rules).length > 0 ? { breakRules: rules } : {}), onOff(settings, "w:autoHyphenation") === true ? { hyphenation: readHyphenation(settings) } : {}), olderMode === void 0 ? {} : { compatibilityMode: olderMode }), onOff(compatibility, "w:suppressTopSpacing") === true ? { suppressesTopSpacing: true } : {}), unsupported ? { unsupported } : {});
};
/**
* The faces of the fonts a document embeds, which Word draws text in those fonts in. Each is the face of the font the
@@ -38319,7 +38446,7 @@ var docxLayout = (function(exports) {
* Reads a document's body (`w:body`), with the other parts of the document.
*/
var readContent = (writtenBody, writtenParts, { guess = false } = {}) => {
- var _writtenParts$dataSto, _parts$otherListIds, _parts$otherListIds2, _parts$settings, _fontOf$size2, _notesByKind$kind$get, _ref31, _ref32, _ref33, _ref34, _documentContent$unsu;
+ var _writtenParts$dataSto, _parts$otherListIds, _parts$otherListIds2, _parts$settings, _parts$webSettings, _fontOf$size2, _notesByKind$kind$get, _ref32, _ref33, _ref34, _ref35, _documentContent$unsu;
const stores = (_writtenParts$dataSto = writtenParts.dataStores) !== null && _writtenParts$dataSto !== void 0 ? _writtenParts$dataSto : /* @__PURE__ */ new Map();
const body = withBoundTextWritten(writtenBody, stores);
const parts = _objectSpread2(_objectSpread2({}, writtenParts), {}, {
@@ -38341,7 +38468,8 @@ var docxLayout = (function(exports) {
const feLayout = onOff(childrenOf(find(settings, "w:compat")), "w:useFELayout") === true;
const openTypeFeatures = wordSettingsOf(childrenOf(find(settings, "w:compat"))).some(({ "w:name": name, "w:val": value }) => name === "enableOpenTypeFeatures" && isOn(value));
const eastAsianRules = readEastAsianRules(settings);
- const readerOf = (inHeader) => _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({
+ const divisions = new Map(divisionsIn(childrenOf(find(childrenOf((_parts$webSettings = parts.webSettings) === null || _parts$webSettings === void 0 ? void 0 : _parts$webSettings["w:webSettings"]), "w:divs"))));
+ const readerOf = (inHeader) => _objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2(_objectSpread2({
styles,
numbering,
listIds,
@@ -38350,7 +38478,7 @@ var docxLayout = (function(exports) {
fields: [],
counters: /* @__PURE__ */ new Map(),
notesInTextBoxes: /* @__PURE__ */ new Set()
- }, decimalSymbol === void 0 ? {} : { decimalSymbol }), mathsSettings), eastAsianRules === void 0 ? {} : { eastAsianRules }), guess ? { guess } : {}), compatibilityMode === void 0 ? {} : { compatibilityMode }), feLayout ? { feLayout } : {}), openTypeFeatures ? { openTypeFeatures } : {});
+ }, decimalSymbol === void 0 ? {} : { decimalSymbol }), mathsSettings), eastAsianRules === void 0 ? {} : { eastAsianRules }), guess ? { guess } : {}), compatibilityMode === void 0 ? {} : { compatibilityMode }), feLayout ? { feLayout } : {}), openTypeFeatures ? { openTypeFeatures } : {}), divisions.size > 0 ? { divisions } : {});
const elements = unwrap(joinRemovedMarks(contentOf$3(body), styles, {
nested: false,
showDeleted: false,
@@ -38667,7 +38795,7 @@ var docxLayout = (function(exports) {
if (notePropertiesOf("footnote", index).position === "beneathText") sections[index] = _objectSpread2(_objectSpread2({}, section), {}, { footnotesBeneathText: true });
});
const documentContent = _objectSpread2(_objectSpread2(_objectSpread2({
- blocks,
+ blocks: withDivisions(blocks),
sections,
footnotes,
footnoteSeparator: footnotes.size > 0 ? readNoteContent("footnote", "separator") : [],
@@ -38680,7 +38808,7 @@ var docxLayout = (function(exports) {
relativeReferences: markers.relative,
endnoteReferences
}, parts.fonts !== void 0 && parts.fonts.length > 0 ? { fonts: parts.fonts } : {}), readSettings(parts.settings));
- return _objectSpread2(_objectSpread2({}, documentContent), withoutUndefined({ unsupported: (_ref31 = (_ref32 = (_ref33 = (_ref34 = (_documentContent$unsu = documentContent.unsupported) !== null && _documentContent$unsu !== void 0 ? _documentContent$unsu : footnotes.size > 0 ? notesUnsupported("footnote") : void 0) !== null && _ref34 !== void 0 ? _ref34 : endnotes.length > 0 ? notesUnsupported("endnote") : void 0) !== null && _ref33 !== void 0 ? _ref33 : endnoteSections.some((section) => sections.slice(section + 1).some(({ textRunsDown }) => textRunsDown !== sections[section].textRunsDown)) ? "endnotes from a section followed by one whose text runs another way" : endnoteSections.length > 0 && sections[sections.length - 1].textRunsDown !== void 0 ? "endnotes after text that runs down the page" : void 0) !== null && _ref32 !== void 0 ? _ref32 : unwrittenNumber ? "notes numbered in a format not yet written" : void 0) !== null && _ref31 !== void 0 ? _ref31 : unseenNumbering }));
+ return _objectSpread2(_objectSpread2({}, documentContent), withoutUndefined({ unsupported: (_ref32 = (_ref33 = (_ref34 = (_ref35 = (_documentContent$unsu = documentContent.unsupported) !== null && _documentContent$unsu !== void 0 ? _documentContent$unsu : footnotes.size > 0 ? notesUnsupported("footnote") : void 0) !== null && _ref35 !== void 0 ? _ref35 : endnotes.length > 0 ? notesUnsupported("endnote") : void 0) !== null && _ref34 !== void 0 ? _ref34 : endnoteSections.some((section) => sections.slice(section + 1).some(({ textRunsDown }) => textRunsDown !== sections[section].textRunsDown)) ? "endnotes from a section followed by one whose text runs another way" : endnoteSections.length > 0 && sections[sections.length - 1].textRunsDown !== void 0 ? "endnotes after text that runs down the page" : void 0) !== null && _ref33 !== void 0 ? _ref33 : unwrittenNumber ? "notes numbered in a format not yet written" : void 0) !== null && _ref32 !== void 0 ? _ref32 : unseenNumbering }));
};
//#endregion
//#region src/layout/paginate.ts
@@ -38715,13 +38843,18 @@ var docxLayout = (function(exports) {
var EXACT_ABOVE_BASELINE = .8;
var TOP_SPACE_KEPT = 9.6;
var TOP_SPACING_UNKNOWN = "the first line of a page or column, at line spacing Word hasn't shown, in a document that suppresses the space above it";
- /** Whether line spacing is single: none given, or a multiple of 1 */
- var isSingle = (spacing) => spacing === void 0 || spacing.rule === "multiple" && spacing.multiple === 1;
- /** Whether a block has a paragraph whose lines aren't of single spacing, in it or in its table's cells */
- var spacedIn = (block) => block.type === "paragraph" ? !isSingle(block.format.lineSpacing) : block.rows.some(({ cells }) => cells.some((cell) => cell.blocks.some(spacedIn)));
- var OLDER_LEAST_GAP = 135;
- /** Whether a line's room beside drawings is a gap they cut narrower than Word 2010 and before were seen putting text in */
- var narrowGap = (span, within) => span.end - span.start < OLDER_LEAST_GAP && (span.start > within.start + TOLERANCE || span.end < within.end - TOLERANCE);
+ var OLDER_LEAST_GAP = 50;
+ var OLDER_LEAST_GAP_ALIGNED = 94;
+ var OLDER_LEAST_GAP_BESIDE_FRAME = 100;
+ /**
+ * Whether a line's room beside drawings is a gap they cut narrower than Word 2010 and before were seen putting text in, of
+ * text aligned as it is: `width` of it, the room the paragraph's indents leave in it, in the line's row from `top` to
+ * `bottom`, where a frame beside the row makes the gap one beside a frame
+ */
+ var narrowGap = (span, width, within, row, around, alignment) => {
+ const beside = (edge, at) => Math.abs(edge - at) <= TOLERANCE;
+ return width < (around.some(({ drawing, keepOut }) => drawing.frame !== void 0 && keepOut.top < row.bottom && row.top < keepOut.bottom && (beside(keepOut.left, span.end) || beside(keepOut.right, span.start))) ? OLDER_LEAST_GAP_BESIDE_FRAME : alignment === void 0 || alignment === "left" ? OLDER_LEAST_GAP : OLDER_LEAST_GAP_ALIGNED) && (span.start > within.start + TOLERANCE || span.end < within.end - TOLERANCE);
+ };
var AUTOMATIC_SPACE = 14;
/**
* The lines of paragraphs without page references, by the measurer and widths they were laid out with. They are the same
@@ -41221,11 +41354,24 @@ var docxLayout = (function(exports) {
const roomOfRow = (around, y, height, line) => {
const room = roomBeside(around, y, height, within);
if ("below" in room) return room;
- if (compatibilityMode !== void 0 && room.spans.some((span) => narrowGap(span, within))) stopAt("a line beside a drawing or frame in a gap narrower than 135 points, in a document in compatibility mode");
- const spans = room.spans.map((span, offset) => ({
- start: Math.max(span.start - left, indentLeft) + (line + offset === 0 ? firstLineIndent : 0),
- end: Math.min(span.end - left, within.end - left - indentRight)
- })).filter((span) => span.end > span.start + TOLERANCE);
+ const rooms = room.spans.map((span, offset) => ({
+ span,
+ inIndents: {
+ start: Math.max(span.start - left, indentLeft) + (line + offset === 0 ? firstLineIndent : 0),
+ end: Math.min(span.end - left, within.end - left - indentRight)
+ }
+ }));
+ const indentOf = (offset) => offset > 0 ? Math.max(0, firstLineIndent) : 0;
+ const firstLine = line === 0 ? rooms.findIndex(({ inIndents: { start, end } }, offset) => end - start - indentOf(offset) > TOLERANCE) : -1;
+ const narrow = ({ span, inIndents: { start, end } }, offset) => {
+ const width = end - Math.max(start, span.start - left) - (offset === firstLine ? indentOf(offset) : 0);
+ return end > start + TOLERANCE && narrowGap(span, width, within, {
+ top: y,
+ bottom: y + height
+ }, around, block.format.alignment);
+ };
+ if (compatibilityMode !== void 0 && rooms.some(narrow)) stopAt("a line beside a drawing or frame in a gap narrower than Word was seen putting text in, in a document in compatibility mode");
+ const spans = rooms.map(({ inIndents }) => inIndents).filter((span) => span.end > span.start + TOLERANCE);
const ownRoom = within.end - left - indentRight - (indentLeft + (line === 0 ? firstLineIndent : 0)) > TOLERANCE;
if (spans.length === 0 && ownRoom) {
const besideLine = around.filter(({ keepOut }) => keepOut.top < y + height && y < keepOut.bottom && keepOut.left < within.end && within.start < keepOut.right);
@@ -41325,21 +41471,23 @@ var docxLayout = (function(exports) {
};
/**
* What is left out above a paragraph's line at the top of a page or column, in a document that suppresses the space
- * above it (`suppressTopSpacing`), in points. Word leaves out the space above the text of a paragraph's first line
- * there: at exact spacing, all but 9.6 points of the 80% of the line above its baseline, and at least a height, all
- * but 9.6 points of the line, which then ends 9.6 points down, its text's descent at its bottom. So it did at the top
- * of a page after a page break, with the space before the paragraph, which is left out there, at the top of a column,
- * and of a section on a new page, in Calibri 11, Times New Roman 12, Courier New 11 and Calibri 24 alike
- * (`word-stops-top-spacing.docx` ST1 to ST5), and it left a line of single spacing as it is (ST4b). Multiple spacing,
- * at least a height less than the line's own (ST2a), a line on a document grid, the space before a section's first
- * paragraph or a border above it, and a paragraph's later line, haven't been seen. Guessing, nothing is left out
+ * above it (`suppressTopSpacing`), in points. Word leaves out the space above the text of the line there: at exact
+ * spacing, all but 9.6 points of the 80% of the line above its baseline, and at least a height, all but 9.6 points of
+ * that height, whether the line is taller or shorter than it: a line of Calibri 11 at least 12 points ends 2.4 points
+ * higher. So it did in Calibri 11, Times New Roman 12, Courier New 11 and Calibri 24 alike, at the top of a page after
+ * a page break, with the space before the paragraph, which is left out there, at the top of a column, and of a section
+ * on a new page, below the space before its first paragraph there (`word-stops-top-spacing.docx` ST1 to ST5,
+ * `word-stops-top-spacing2.docx` ST6, ST10, ST12), and for a paragraph's later line at the top of the next page too
+ * (ST8). It leaves a line of single or multiple spacing as it is (ST4b, ST7), and the first line of a paragraph with a
+ * border above it (ST11). Multiple spacing of less than a line, a line on a document grid, and a later line of a
+ * paragraph with a border above it haven't been seen. Guessing, nothing is left out
*/
- const cutAbove = (block, line, isFirstLine, above) => {
+ const cutAbove = (block, isFirstLine, borderAbove) => {
var _block$grid;
const spacing = block.format.lineSpacing;
- if (spacing === void 0 || isSingle(spacing)) return 0;
- const cut = spacing.rule === "exact" ? Math.max(0, EXACT_ABOVE_BASELINE * spacing.height - TOP_SPACE_KEPT) : spacing.rule === "atLeast" && line.height <= spacing.height + TOLERANCE ? Math.max(0, line.height - TOP_SPACE_KEPT) : void 0;
- if (cut === void 0 || cut > 0 && (!isFirstLine || above > 0 || ((_block$grid = block.grid) === null || _block$grid === void 0 ? void 0 : _block$grid.linePitch) !== void 0)) {
+ if (spacing === void 0 || spacing.rule === "multiple" && spacing.multiple >= 1 || isFirstLine && borderAbove > 0) return 0;
+ const cut = spacing.rule === "exact" ? Math.max(0, EXACT_ABOVE_BASELINE * spacing.height - TOP_SPACE_KEPT) : spacing.rule === "atLeast" ? Math.max(0, spacing.height - TOP_SPACE_KEPT) : void 0;
+ if (cut === void 0 || cut > 0 && (borderAbove > 0 || ((_block$grid = block.grid) === null || _block$grid === void 0 ? void 0 : _block$grid.linePitch) !== void 0)) {
stopAt(TOP_SPACING_UNKNOWN);
return 0;
}
@@ -41386,8 +41534,9 @@ var docxLayout = (function(exports) {
continue;
}
if (isFirstLine && !placedInColumn && paragraph.joinedUnlike === true) stopAt("a paragraph at the top of a page in one box with the one before, whose between border is another");
+ if (!placedInColumn && block.unknownAtTop !== void 0) stopAt(block.unknownAtTop);
const above = isFirstLine ? spaceAbove() + paragraph.borderAbove : 0;
- const space = above - (suppressesTopSpacing === true && !placedInColumn ? cutAbove(block, linesOf(block, widths, rooms)[index], isFirstLine, above) : 0);
+ const space = above - (suppressesTopSpacing === true && !placedInColumn ? cutAbove(block, isFirstLine, paragraph.borderAbove) : 0);
const theirs = Math.min(spaceAfter, isFirstLine ? spaceAbove() : 0);
const laid = rowsOf(block, widths, rooms, index, position + space, {
top: position + theirs,
@@ -41963,8 +42112,6 @@ var docxLayout = (function(exports) {
};
const layOutTable = (block, onNextPage) => {
var _table$rows$borderBot, _table$rows;
- const topSpacingUnknown = suppressesTopSpacing === true && spacedIn(block);
- if (topSpacingUnknown && !placedInColumn) stopAt(TOP_SPACING_UNKNOWN);
const width = columnsSection().columns[column];
const table = sizedToPlace(block, width);
const merges = mergesOf(table);
@@ -41988,7 +42135,6 @@ var docxLayout = (function(exports) {
guesses.forEach((reason) => stopAt(reason));
throw new HeaderRowsAlone(guesses);
}
- if (topSpacingUnknown) stopAt(TOP_SPACING_UNKNOWN);
const page = pageCount;
nextColumn();
while (newPage && pageCount === page) nextColumn();
@@ -43274,6 +43420,7 @@ var docxLayout = (function(exports) {
theme: partOf("theme"),
numbering: partOf("numbering"),
settings: partOf("settings"),
+ webSettings: partOf("webSettings"),
headersAndFooters: new Map(headersAndFooters.flatMap(({ id, path }) => {
const part = rootOf(parts.get(path));
return part ? [[id, {
@@ -43330,6 +43477,7 @@ var docxLayout = (function(exports) {
styles: readTextStyles((_read$styles = read.styles) !== null && _read$styles !== void 0 ? _read$styles : { "w:styles": [] }, read.theme && readThemeFonts(read.theme)),
numbering: read.numbering,
settings: read.settings,
+ webSettings: read.webSettings,
headersAndFooters: new Map([...read.headersAndFooters].map(([id, { content }]) => [id, content])),
footnotes: (_read$footnotes = read.footnotes) === null || _read$footnotes === void 0 ? void 0 : _read$footnotes.notes,
endnotes: (_read$endnotes = read.endnotes) === null || _read$endnotes === void 0 ? void 0 : _read$endnotes.notes,
diff --git a/usage/layout.md b/usage/layout.md
index 92ce4e06cb..4f39c5cd59 100644
--- a/usage/layout.md
+++ b/usage/layout.md
@@ -217,6 +217,7 @@ The pages are laid out with the widths and heights of the characters of the font
- tables, with their columns' widths (`columnWidths`, or their cells' widths), their rows' heights, cell margins and borders. The columns of a table given no widths are sized to their text, as Word sizes them: each as wide as its longest line, or narrower when they don't all fit, but never narrower than its longest word, and a column whose cells give it a width keeps it. A cell merged across columns (`columnSpan`) widens them where its longest line needs more room, each in proportion to how wide it is, and a table in a cell counts as wide as its columns. In a table whose cells all have widths, a column with a word longer than its cells give it is widened to fit the word, and the other columns are narrowed to make room, as Word does, unless the table's layout is fixed. A table with a width of its own in twips is fitted to it, as Word fits it: when its columns are narrower, they are widened in proportion, and when they are wider, they are narrowed toward their longest words, or, when its layout is fixed, whatever is in them, each by the same share of the room for its text. When a word is longer than the table, its column is as wide as the word, and the table goes past the margin. Without a width of its own in twips, or with all of the width, a table whose columns' longest words don't fit in the room has each column narrowed to a share of it in proportion to its longest word, whatever width its cells give it, and the words break across lines, as Word breaks them. A table of a share of less than the width (`WidthType.PERCENTAGE`) whose columns' longest words don't fit in its share is as wide as they are, up to the room, and past it is narrowed as one of all of the width. A table sized to its text, or of a share of the width, has half of each of its left and right borders inside the room it fills, outside its columns, as Word draws them, where one of a width in twips has them outside it. Where the rows of a table give a column different widths, each column is as wide as the widest a row gives it, and a cell merged across columns that is wider than they are widens the last of them, before they are fitted to the table's width, in twips or as a share of the width, or, without one, narrowed to the room, unless its layout is fixed. In [templates](#templates), a row that starts past the first column (`w:gridBefore`) gives it its width before it (`w:wBefore`), as a cell does. A word in a cell merged across columns that is longer than they are wide is shared among them in proportion to each column's longest word and its longest line, or its width, added together, as Word shares it, and those columns keep its width when the others are narrowed. A long word with more text beside it widens them as its line does. Rows break across pages between the lines of their cells, as Word breaks them, keeping to widow and orphan control and lines kept together, and with room on the page for the space after a cell's paragraph that ends there. They move to the next page whole when a cell would have none of its lines on the page, when they are kept whole (`cantSplit`), and when the page hasn't room for the height they are set to. A row kept whole, or whose paragraph is kept together, that is taller than a page moves to a new page and breaks there as other rows do, and a row set to a height taller than a page takes a page of its own, cut off at its bottom, as Word lays them out. The text of a cell merged down from such a row, or to it from a row above, goes in all of its set height, past the bottom of the page, and the rest goes on in the rows after it on the next page, keeping to widow control. The row's footnotes start at the bottom of the next page, one after the other. A header row set to a height taller than a page isn't repeated on the next page, and what comes after its table goes on the page after the one the table ends on, as Word lays it out. A row set to at least a height taller than a page, whose text is taller than a page too, breaks where its text does, and each part of it fills its page. In columns, a row kept whole, or whose paragraph is kept together, that is taller than a column goes down only the first column of each page, from the top of a new page unless it is at the top of this one, as a paragraph kept together does, and what comes after one set to a height taller than a column goes on the next page. Where a table breaks across pages, Word draws its bottom border below the last of it on the page, which takes room there too, or its cells' own bottom borders. Header rows are repeated at the top of each page and column a table is on, and they aren't left alone at the foot of a page: when none of the row after them goes there, as it is kept whole, kept with the next or set to a height, they go on to the next page with it, as Word moves them. The text of a cell merged down rows (`verticalMerge`) goes down from below the border above its first row across the others, to above the border below the last, and makes the last of them taller when it needs the room. Where one of its rows breaks across pages, its text breaks with the row, as far down the page as its lines go, keeping to widow control, as Word breaks it, and the rest of it goes on from the top of its rows on the next page, and on across the pages after. Where the page breaks between its rows, as the next is kept whole or set to a height, the text that doesn't fit in its rows on the page goes on in its rows on the next, all of it where widow control leaves none of it on the page. A table in a cell breaks with its row, between its own rows and in them between the lines of their cells, as Word breaks it: as a table in the text breaks, keeping to widow control, with its bottom border below the last of it on the page and its cells' margins around their lines on each page, and with its rows kept whole, or of a set height, moving to the next page whole. On the next page, Word draws its top border above the rest of it, and doesn't repeat its header rows. A table in a cell merged down rows breaks as one in a cell of a row, and so does one with cells merged down its rows whose text is in their first rows, or whose rows are all on the page. An empty paragraph that ends a cell after a table in it takes no room, as Word lays it out
- table formatting, as Word lays it out. Borders come from the table's style and the table (`borders`), side by side, from its cells (`TableCell`'s `borders`), and from the parts of its style for some of its cells. Where two cells meet, Word draws the heavier of their borders, by its width and a weight for its style, but makes room for the wider, so each row is as much taller as the widest border above its cells and below those above it. Double, triple and the other styles of border take the room Word gives them, such as three times their width for a double border, and a border's `space` adds to it. In [templates](#templates), an art border takes as many points above and below a cell's text as its size. A cell's text is as far in from its left and right edges as its margin, or half its own border there when that is more, whichever of two borders that meet Word draws. A row of an exact height (`HeightRule.EXACT`) has the border above it inside that height, and one of at least a height has it outside, as Word lays them out. A row is as tall as its tallest cell's text, with the largest margins above and below of its cells, which needn't be the same cell's. Space between cells (`cellSpacing`) goes around each cell and inside the table's edges, and the table keeps its width, its columns narrowed for the space as Word narrows them, or widened to it in proportion, the space aside, and a column with a long word widened for it as in a table without the space. Where its rows give a column different widths, they are evened out as in a table without it, unless its layout is fixed. Each cell's own borders take room inside it, left and right of its text as well as above and below it, and the table's own go around the space. Where such a table breaks across pages, Word draws its bottom border below the last of it on the page, and its top border above the rest of it on the next, but for below its header rows repeated there, which have it above them. A row's own space between its cells (`TableRow`'s `cellSpacing`) goes around its cells in place of the table's, at the table's edges too, as do its own borders (`w:tblPrEx`, in [templates](#templates)), and the table's columns are as wide as they would be without it, where the table has a width of its own and its cells have widths. Space given as a share of the table's width, or of the type `auto`, is none, as Word lays them out. A row whose first cell's first paragraph is kept with the next (`keepNext`) is kept on the page with the next row, or, for the last row, with the paragraph after the table, and rows kept together that don't fit on a page of their own start a new page and break where it ends. Text that runs up or down a cell (`textDirection`) makes a row of only such cells as tall as a line of its last paragraph's mark, and a row with other cells no taller, as Word breaks it into lines as long as the row is tall, and a row with it breaks across pages as other rows do, the text on the page of its first part. In a table sized to its text, its column is as wide as a line of each of its paragraphs with text, however long, with the space before and after them, its lines as far apart as Word lays them out at their line spacing: a quarter of their size further than their size in Calibri, and as far as across the page in Times New Roman, Arial, Cambria and Courier New. A long word in it widens nothing, and the table's other columns are sized as they would be beside any other column. Text down with East Asian characters upright is laid out as text that runs down, and across with them on their side as text across. A table sized to its text that is indented (`indent`) is sized in the room the indent leaves, and one indented by a share of the width (`WidthType.PERCENTAGE`) is laid out as though it weren't indented, as Word lays it out. The parts of a table style for some cells, such as its first row, its last column or its bands of rows, apply where the table turns them on (`tableLook`), and where it doesn't say, as Word turns them on: its first row and column and its bands of rows. A header of several rows (`tableHeader`) is the table's first row, all of it, with the parts for its corner cells in each of its rows, and the bands of rows start below it, as Word applies them, but for a header of three rows or more with the first row turned off, whose bands start at its first row. A table style's own cell margins apply to its cells, its rows kept whole (`w:cantSplit`) are kept whole, and its own row height doesn't apply, as in Word, and a part of it for some rows gives them its height, and keeps them whole, and not its space between cells. In [templates](#templates), a row's own table borders and cell margins (`w:tblPrEx`) apply to its cells, cells merged across columns as old versions of Word wrote them (`w:hMerge`) are one cell across them, and a cell whose text Word is told not to wrap (`w:noWrap`) has it wrapped all the same, and text fitted to its cell (`w:tcFitText`) is on one line a paragraph, as Word lays them out. In a table sized to its text, the one makes its column as wide as its lines, as though they didn't wrap, and the other as wide as its column in the table's grid. In [templates](#templates), an empty last paragraph of a cell whose mark is hidden (`w:hideMark`) takes no room
- sections, with their page sizes, margins, columns, headers and footers, how they start, and their page numbering. Page numbers are written in Word's number formats as Word writes them, such as roman numerals, letters, words ("twenty-one") and the numbers of other languages, but for those it leaves blank (see below), and with chapter numbers in front of them (`chapterHeadingLevel`), such as 2-5 for page 5 of chapter 2. Each column's lines are broken at its own width, so a paragraph that goes on into a column of another width is broken again there, as Word breaks it. Widow control counts the lines left for the next column as they are broken in the column before, as Word counts them, and a table sized to its text keeps the widths it was sized to in each column it goes on into, as Word keeps them, going past the edge of a narrower one. Columns before a continuous section break are evened out, as Word evens them out, unless a column break is in them or a section in them started in the next column, and the next section starts below the longest. A section that starts in the next column (`SectionType.NEXT_COLUMN`) starts in the next column of the page when the section before has as many columns and one is left, as Word starts it, and on a new page otherwise. When its own columns are of other widths, it is laid out in the page's, where they are and as wide as they are, as Word lays it out, and in its own on the pages after. Its footnotes are laid out in its own columns. A continuous section numbered afresh (`pageNumbers: { start }`) leaves the page it starts on its number, and numbers the next on from its own first number, as Word does: 8 after a section numbered from 7 starts on page 12. When none of it fits on the page before, the page it starts at the top of is its first, numbered 7. One that starts in the next column of a page numbers on through the document, as Word numbers it. A gutter is beside the page's text, or above it in a document that puts it at the top (`w:gutterAtTop`), as Word takes it from the page's height, on every page with mirrored margins too, and below a negative top margin, which the header doesn't push the text below. A paragraph kept together that is taller than a column goes down only the first column of each page, as Word lays it out, from the top of a new page unless it is at the top of this one, and what follows it goes on below it. In columns of different widths it does when it is taller than each of them. One taller than some of them but not others goes in the first column, from where it is, that it fits in, as Word moves it: from the top of a narrow first column to a wide second, and past a narrow second column to a new page, in 3 columns or more as in 2, and the paragraphs kept with the next before it go with it. Paragraphs kept with the next before one taller than each column go to the new page with it, unless they are at the top of the page already, and it moves on to the next page, as Word moves them, so they are alone on theirs. A section that ends with a table has a line below it for the empty paragraph that ends the section, as Word has it
+- in [templates](#templates), the divisions of a web page that paragraphs are in (`w:divId`), as documents made from HTML have them, laid out as Word lays them out: a paragraph is indented by the margins left and right of its division and of the divisions that division is in, with the division's borders outside them as a paragraph's borders, and a division's paragraphs are in one box, with its margins above its first and below its last. And pages printed two to a sheet or folded as a booklet (`w:printTwoOnOne` and `w:bookFoldPrinting`), which Word lays out as the section's pages, as it does without
- a section's document grid (`grid`), as Chinese and Japanese documents and Word's templates for them have it. On a grid of lines (`DocumentGridType.LINES`), each line takes as many of the grid's lines (`linePitch`) as its own height needs, with its text in the middle, as Word lays it out: at 360 twips, a line of Times New Roman of up to 15.5 points takes one, and from 16 points two. Multiple line spacing takes the grid's lines times the spacing when that is more, so 1.08 lines are 388.8 twips, at least a height takes that height when it is more, and exact spacing is as it is without the grid. The space before and after a paragraph isn't put on the grid's lines, a line of space before or after (in lines) is one of them, and the room below the last line's text can go below the bottom of the page. The lines of table cells, headers and footers aren't on the grid, nor the lines above footnotes and endnotes, but footnotes and endnotes are. A paragraph whose `snapToGrid` is off, in documents Word made, isn't on the grid's lines. A grid of lines and characters (`DocumentGridType.LINES_AND_CHARS`) also adds its `charSpace`, in 4096ths of a point, after each character, and a quarter of a character more between Chinese, Japanese or Korean characters and Latin letters, as Word does. One that snaps to characters (`DocumentGridType.SNAP_TO_CHARS`) puts each Chinese, Japanese or Korean character in as many cells as it needs, as many cells as fit across a column at the size of the Normal style's text and the `charSpace` more, spread evenly across it, and the other text between them on a line in as many cells as it needs together, with text spaced out by its run (`characterSpacing`) as wide as it is spaced. In columns of different widths each column has cells of its own. A left tab, and a line beside a drawing, start at the next cell, Chinese, Japanese or Korean text at a right or centred tab ends at the stop, or is centred on it, in its cells, a picture in the line takes as many cells as it needs after the text before it, a word longer than its line goes on to the next, a word with soft hyphens breaks at the last whose part fits in the cells left, and a justified or distributed line isn't squeezed. Characters of indents are the grid's characters, an indent of part of one is rounded up to the next cell, and a hanging indent's other lines go that many more cells in, as Word lays them out. Footnotes are on the grid as the body is, and endnotes on the last section's grid. Kerned text is kerned on a grid of characters, and on one that snaps to characters takes as many cells as it needs kerned. On a grid of lines and characters, text in a font that isn't East Asian, such as digits in Calibri, has no quarter of a character beside Chinese, Japanese or Korean characters. Emphasis marks take their room in the line before it is put on the grid, with multiple line spacing and at least a height too. A run with `snapToGrid: false` isn't on a grid of characters, and headers and footers aren't. Sections whose text direction (`page: { textDirection }`) runs across the page are laid out as those without one
- text that runs down the page (`page: { textDirection: PageTextDirectionType.TOP_TO_BOTTOM_RIGHT_TO_LEFT }`, and the other directions down it of documents Word made), as Chinese and Japanese documents have it, laid out as Word lays it out: each line runs from the top margin to the bottom one, and the lines go across the page from the right margin, or from the left for the directions that put them that way, each as far from the one before as it is tall, on the section's grid if it has one. Chinese, Japanese and Korean characters in fonts whose characters are all an em, such as MS Mincho and SimSun, are an em down the line, and Latin text is on its side, as wide as it is across a page. Indents are from the top and bottom margins, and the space before and after a paragraph is across the page. Half-width katakana are on their side, half an em each. A tab to a left stop, a border around text or around the paragraph, emphasis marks, superscript and subscript, and a justified line with spaces take the room they take across the page, and a footnote goes below the text, at the left of the page. Two digits set across the line (`w:eastAsianLayout w:vert`) take as much room along it as the line is tall. A gutter is beside the right margin, a negative top or bottom margin is as far from the edge as a positive one, and a grid that snaps to characters puts its cells along the lines. The header and footer stay across the top and bottom of the page, and a header doesn't push the lines down. A section whose text runs down the page starts a new page after one whose text runs across it, as a continuous section does too, and a continuous one goes on on the page after text that runs down it the same way
@@ -270,9 +271,9 @@ It stops at the first thing it can't lay out yet, and the page numbers of the he
- tracked changes Word hasn't been seen laying out: a field only part of which is deleted, a deleted paragraph mark before a content control, or at the end of one with no paragraph after it, a deleted section break before a table, or between sections that start differently, after the first, a list in a deleted table row, a cell merged down from a deleted row with something in it, a deleted row whose borders above and below it take different room, or, at the top or bottom of the table, other room than the table's own top or bottom border would, a deleted row in a table with borders and space between its cells at its top or bottom, or with borders other than the rows' around it, and a deleted row in a header of several rows (`tableHeader`) whose table style formats some of its rows by where they are, such as its first row or its bands
- a date or time (a `DATE` or `TIME` field, or a `DayLong`, `MonthLong`, `YearLong` and the like) in the text, a footnote or an endnote, as Word writes the date and time it opens the document, whose width changes with them. One in a header or footer is laid out as it is written
- a page reference, number of pages or page number in a format other than those above, or with a picture Word's text isn't known for, as above, or past what its format writes, such as 781 in letters
-- in a document in compatibility mode, which Word lays out as Word 2010, 2007 or 2003 did (one saved by those versions of Word, or by an application that writes their mode, or given `compatibility: { version: 14 }`, 12 or 11), what those versions lay out unlike Word 2013 or haven't been seen laying out: a tab to a stop past the end of the line, whose text they put past the margin, a line beside a picture or frame in a gap narrower than 135 points, which they may leave empty, a page break at the end of a paragraph, a table that text wraps around, a table sized to its text in a table cell, indented or as a share of the width, or widened for a long word with no width of its own, a distributed paragraph, or one justified for Thai or with a low kashida, ligatures unless Word's `enableOpenTypeFeatures` is on, as Word 2010 writes it, and any of the `compatibility` options, which Word 2013 leaves out in its own mode, but the older ones may follow; and in Word 2007's and 2003's modes, Chinese, Japanese and Korean text and VML drawings that take room. The rest is laid out as in Word 2013's mode, but that justified lines aren't squeezed, so they break as lines aligned left do, and a table sized to its text has its first and last cells' margins beside the page's text, as Word 2010 and before line a table's text up with the margins rather than its borders. A mode Word doesn't have, such as 13, stops the layout
-- a compatibility setting that changes how Word lays out lines in compatibility mode 15 in a way not yet followed: with `suppressTopSpacing`, the first line of a page or column at at-least line spacing less than its text's height or at multiple spacing, a paragraph's line after its first at the top of a page, and such a line in a table cell, on a document grid, or below the space before a section's first paragraph or a border; with `useFELayout`, Chinese, Japanese and Korean text, and any text where another of the East Asian `compatibility` options is on too. `suppressTopSpacing` is followed otherwise: Word leaves out the space above the text of the first line of a page or column at exact spacing, all but 9.6 points of the 80% of the line above its baseline, and at at-least spacing, all but 9.6 points of the line, and leaves a line of single spacing as it is. `useFELayout` leaves the lines of other paragraphs as they are. The other `compatibility` options, which ask for an older Word's or another application's layout, Word lays out lines with as without them in its own mode, so they don't stop it, and `doNotUseHTMLParagraphAutoSpacing` is followed. In [templates](#templates), Word's own settings (`overrideTableStyleFontSizeAndJustification`, `enableOpenTypeFeatures`, `doNotFlipMirrorIndents`, `differentiateMultirowTableHeaders`, `useWord2013TrackBottomHyphenation`, `allowHyphenationAtTrackBottom` and `allowTextAfterFloatingTableBreak`) leave Word's lines as they are too, and those it doesn't know, such as ones a later Word may write, stop it whether they are on or off. Settings for other applications, whose `w:uri` isn't Word's, are left to them, as Word leaves them
-- in [templates](#templates), what `docx` doesn't write and Word lays out in ways not yet followed: space between a row's cells as a share of the table's width, a table indent of a type other than twips or a share of the width, a row with table properties of its own other than borders and cell margins, a table style with formatting of its rows or cells other than its rows' height, its rows kept whole and its cells' margins, or a part of one for some cells with properties other than borders, margins, a height for its rows, its rows kept whole and space between cells, text with a phonetic guide, text fitted to a width with other than text in it, wider than its line or in runs of other sizes or fonts, two lines in one with brackets, of Chinese, Japanese or Korean text or at a size of a fraction of a point, and horizontal in vertical text, ink and other content parts, a subdocument, a paragraph in an HTML division, cells merged across columns as old versions of Word wrote them with text after the first, footnotes in columns of their own, endnotes numbered afresh on each page, footnotes numbered afresh on each page of a section that shares a page with another, notes numbered on through the document after a section that numbers its own afresh, or in a format not yet written, footnotes anywhere but at the bottom of the page or just below the text, and below the text of columns, after space below the page's last paragraph or going on across pages, endnotes at the end of each section when the document's settings put them there, an endnote with a mark of its own in place of its number, a content control bound to custom XML or the document's properties that Word fills in with other text than is written in it when it opens the document (one whose text is already the XML's is laid out as it is), pages printed as a folded booklet, styles Word updates from the document's template when it opens it, and an imported document (`w:altChunk`) in another format than `.docx`, such as HTML, RTF or plain text, which Word converts its own way, of more than one section, whose formatting is kept as it is (`w:matchSrc`), with a style of its own where its defaults leave out some of the template's, or with a page reference or number of pages, whose number `docx` can't write in it
+- in a document in compatibility mode, which Word lays out as Word 2010, 2007 or 2003 did (one saved by those versions of Word, or by an application that writes their mode, or given `compatibility: { version: 14 }`, 12 or 11), what those versions lay out unlike Word 2013 and haven't been seen laying out: text after a tab past the end of the line that goes more than 941 points past the margin, a line beside a frame in a gap narrower than 100 points, or beside a picture or a table that text wraps around in one narrower than 50 points, or 94 for text not aligned left, which they may leave empty, a table that text wraps around sized to its text, lined up across the page or with no distance from the text beside it, a table sized to its text as a share of the width, or in a table cell indented or as a share of its width, a table with no width of its own widened for a long word past the room for it or with its rows evened out, and any of the `compatibility` options, which Word 2013 leaves out in its own mode, but the older ones may follow; and in Word 2007's and 2003's modes, Chinese, Japanese and Korean text in an East Asian language, or beside characters past ASCII that aren't East Asian, such as curly quotes, and VML drawings that take room other than a text box in the line. The rest is laid out as in Word 2013's mode, but that: justified and distributed lines, and lines justified for Thai or with a low kashida, aren't squeezed, so they break as lines aligned left do; a tab to a stop past the end of the line goes to that stop on the line, past the margin, and the rest of the paragraph's text stays on that line; a table sized to its text has its first and last cells' margins beside the room for it, the page's text or what its indent leaves of it, as Word 2010 and before line a table's text up with its indent rather than its borders, but in a table cell; a table that text wraps around is placed with its first cell's text where it is placed across the page; ligatures are drawn only with Word's `enableOpenTypeFeatures` on, as Word 2010 writes it; and in Word 2007's and 2003's modes, Chinese and Japanese text breaks only at its spaces, as Latin text does, and a text box's outline takes no room in its line. A mode Word doesn't have, such as 13, stops the layout
+- a compatibility setting that changes how Word lays out lines in compatibility mode 15 in a way not yet followed: with `suppressTopSpacing`, a line at the top of a page or column at multiple spacing of less than a line or on a document grid, and a paragraph's later line there below a border above it; with `useFELayout`, Chinese, Japanese and Korean text beside other text, such as Latin letters and digits, which Word spaces apart unless the paragraph turns both of its automatic spacings off (`w:autoSpaceDE` and `w:autoSpaceDN`, in templates), and any text where another of the East Asian `compatibility` options is on too. `suppressTopSpacing` is followed otherwise: Word leaves out the space above the text of a line at the top of a page or column, a paragraph's first or a later one, and below the space before a section's first paragraph too, at exact spacing all but 9.6 points of the 80% of the line above its baseline, and at at-least spacing all but 9.6 points of that height, whether the line is taller or shorter than it, and leaves a line of single or multiple spacing as it is, as it does the first line of a paragraph with a border above it and the lines of a table's cells. `useFELayout` leaves the lines of other paragraphs as they are. The other `compatibility` options, which ask for an older Word's or another application's layout, Word lays out lines with as without them in its own mode, so they don't stop it, and `doNotUseHTMLParagraphAutoSpacing` is followed. In [templates](#templates), Word's own settings (`overrideTableStyleFontSizeAndJustification`, `enableOpenTypeFeatures`, `doNotFlipMirrorIndents`, `differentiateMultirowTableHeaders`, `useWord2013TrackBottomHyphenation`, `allowHyphenationAtTrackBottom` and `allowTextAfterFloatingTableBreak`) leave Word's lines as they are too, and those it doesn't know, such as ones a later Word may write, stop it whether they are on or off. Settings for other applications, whose `w:uri` isn't Word's, are left to them, as Word leaves them
+- in [templates](#templates), what `docx` doesn't write and Word lays out in ways not yet followed: space between a row's cells as a share of the table's width, a table indent of a type other than twips or a share of the width, a row with table properties of its own other than borders and cell margins, a table style with formatting of its rows or cells other than its rows' height, its rows kept whole and its cells' margins, or a part of one for some cells with properties other than borders, margins, a height for its rows, its rows kept whole and space between cells, text with a phonetic guide, text fitted to a width with other than text in it, wider than its line or in runs of other sizes or fonts, two lines in one with brackets, of Chinese, Japanese or Korean text or at a size of a fraction of a point, and horizontal in vertical text, ink and other content parts, a subdocument, a paragraph in an HTML division with indents, borders or space before or after it of its own, at the top of a page or column, in a table cell, note, header, footer or text box, or in a division next to another, next to a paragraph with space between them, in another with borders or other margins above or below, or that is a quotation or a page's body, cells merged across columns as old versions of Word wrote them with text after the first, footnotes in columns of their own, endnotes numbered afresh on each page, footnotes numbered afresh on each page of a section that shares a page with another, notes numbered on through the document after a section that numbers its own afresh, or in a format not yet written, footnotes anywhere but at the bottom of the page or just below the text, and below the text of columns, after space below the page's last paragraph or going on across pages, endnotes at the end of each section when the document's settings put them there, an endnote with a mark of its own in place of its number, a content control bound to custom XML or the document's properties that Word fills in with other text than is written in it when it opens the document (one whose text is already the XML's is laid out as it is), pages printed as a booklet folded the other way round, for text that runs right to left, styles Word updates from the document's template when it opens it, and an imported document (`w:altChunk`) in another format than `.docx`, such as HTML, RTF or plain text, which Word converts its own way, of more than one section, whose formatting is kept as it is (`w:matchSrc`), with a style of its own where its defaults leave out some of the template's, or with a page reference or number of pages, whose number `docx` can't write in it
When laying out the pages again with the page numbers it worked out still changes them after three passes, as when a table of contents wraps one way with a number and the other way without it, all of them are left blank, and `layoutDocument` lays out the pages without them.
The unique identifier for this abstract numbering definition.