Files
docx/scripts
Dolan 21d3769623 feat(layout): write page numbers in every format, with chapter numbers, as Word does (#3618)
* feat(layout): write page numbers in every format, with chapter numbers, as Word does

docx/layout wrote page numbers in decimal, roman numerals, letters and a few
more, and stopped at the rest and at chapter numbers. Two probes saved from
Word settle how Word writes each of ST_NumberFormat's formats in page numbers,
page references and lists, and how it writes chapter numbers, and the layout
now writes them so: the scripts of other languages, words, enclosed numbers and
counting systems, up to the numbers Word writes, and the chapter number of the
last heading its style numbers before each page reference.

Lists a paragraph's style numbers it in are numbered too. pageNumbers takes
chapterHeadingLevel, written as w:chapStyle, and PageNumberSeparator.EN_DASH is
written as the schema's enDash.

* fix(layout): take a style's list and level each from the nearest style that gives it

A paragraph style based on another can give its level (w:ilvl) alone and take
its list (w:numId) from the style it is based on, as Word's styles inherit
each property on its own. The reader only kept a style's numbering when it gave
the list, so such a style's paragraphs were numbered at the base style's level.

* docs(layout): say page numbers are written in Word's formats but for those listed as left blank

The line said every format was written, but the list of what is left blank names
Thai and Hindi words, and page numbers Word writes as an error.
2026-10-01 23:56:35 +01:00
..