diff --git a/ROADMAP.md b/ROADMAP.md index 56d98b4d6b..64b2540868 100644 --- a/ROADMAP.md +++ b/ROADMAP.md @@ -1,6 +1,6 @@ # WordCraft roadmap -> **Last reviewed:** 2026-10-31 · **Last updated:** 2026-11-21 · **Change:** trivial (table rows split across pages: a cell's first paragraph on the page can split even when only one line fits, if the row starts at the top, with or without its own headers, or continues from the previous page (#6823)); previously trivial (progress log: TIFF picture chooser, drop and pasted-path routing, #6704); previously minor (added layout.fitOnePage and its Layout › Page Setup ribbon button to condense a multi-page document by one page while preserving typography hierarchy); previously minor (#3398: persistent screen paper colors; parity estimates unchanged); previously minor (#3693: additional Delete Previous Sentence command and shortcut; Word-parity estimates unchanged) +> **Last reviewed:** 2026-10-31 · **Last updated:** 2026-11-21 · **Change:** trivial (table rows split across pages: a cell's first paragraph on the page can split even when only one line fits, if the row starts at the top, with or without its own headers, or continues from the previous page (#6823)); previously trivial (release wrap areas when strict column balancing moves the anchor line, #6821); previously trivial (balanced columns keep lines together from Word 2013's layout, #6821); previously trivial (progress log: TIFF picture chooser, drop and pasted-path routing, #6704); previously minor (added layout.fitOnePage and its Layout › Page Setup ribbon button to condense a multi-page document by one page while preserving typography hierarchy); previously minor (#3398: persistent screen paper colors; parity estimates unchanged); previously minor (#3693: additional Delete Previous Sentence command and shortcut; Word-parity estimates unchanged) > **CLI path update:** 2026-11-04 · Options before a non-Unicode input filename no longer make the CLI reject that filename; text option values still require Unicode; `run --file` and `run --script` retain native paths. No ranked gap or readiness estimate changes. > **Floating anchor row segments:** 2026-11-07 · A floating anchor after a manual page/column break counts visible content on the far side of the same wrapped row. Marker-only cover anchors retain their previous-page rule. Synthetic picture spacing, placement and history controls; no new native Word measurement. Readiness estimates unchanged. @@ -151,7 +151,11 @@ Ranked, to beta (detail and remaining milestones in [docs/roadmap.md](docs/roadm ## Progress log +- 2026-11-21: Layout: strict column balancing measures a kept paragraph again in each candidate column, so a float in one column does not make the paragraph skip another where it fits (#6821). Readiness estimates unchanged. + - 2026-11-20: `wordcraft-cli mcp` starts only with both `--automation-read-root` and `--automation-write-root` (shared rule 18, #7124); without them it stops with an error naming the two flags, where it used to serve with access to every file the user can reach. `mcp --connect` is refused until the desktop app confines its control channel to the same roots (#3695, #5819). The help, `docs/mcp.md`, the README and `AGENTS.md` pass both roots in every example. + +- 2026-11-19: Layout: when strict column balancing moves an anchor line to the next column, it releases the floating object's wrap area from the abandoned column (#6821). Readiness estimates unchanged. - 2026-11-16: Layout: a row of hyphens after a gap wraps at any hyphen, as in Word (it fills the line and its rest goes on the next), where the whole row moved to the next line. - 2026-11-15: Native, built-in and web Insert/Change Picture choosers offer both TIFF extensions (`.tif`, `.tiff`) alongside other supported pictures; native drops, picked-file inbox dispatch and pasted picture paths recognize the same suffixes (#6704). TIFF decoding remains limited to supported compression. - 2026-10-31: Screen readers hear what the dialogs and their drawn controls are: a dialog is a dialog, where it was only a window, so NVDA says so and reads the text in it (Word Count's figures); a dialog's tabs (Paragraph, Find and Replace, About) are tabs, the one shown selected, as in Word, where they were buttons read as pressed toggles; a colour field says its label and colour ("Font color: #104861"), where its text alone was the colour's hex digits; and each swatch of the colour grid says its colour, where it had no name. Readiness estimates unchanged. @@ -166,6 +170,7 @@ Ranked, to beta (detail and remaining milestones in [docs/roadmap.md](docs/roadm fix/6146-touchpad-scroll-speed - 2026-11-09: Touchpad and mouse-wheel scroll speed settings (#6146): scales Wayland touchpad point input by default (4×) so two-finger scrolling matches desktop speed rather than crawling 1:1, and scales mouse wheel line distance; File › Options › Advanced › Scrolling; commands ui.scrollSpeed and ui.touchpadScrollSpeed. +- 2026-11-15: Layout: from Word 2013's layout (compatibility mode 15), balancing the columns before a continuous break keeps the last two, three or five lines of a paragraph that began on the page before together, keeps a two- or three-line paragraph that begins the last page whole, and holds a paragraph with keep lines together (or keep with next) whole in the first column when the strict rules fit. Synthetic tests also cover a footnote and a float (#6821); mode 14 splits them as before. Readiness estimates unchanged. - 2026-11-14: Save As and Export (also the formats on the Print page) offer Browse in WordCraft… on Linux and the BSDs, as File › Open does, for when the system file dialog doesn't appear (#3535, from VoiceLessQ's #3801). Exporting in the built-in browser lists Export's formats as the types; the chosen type is the format and its extension, which replaces a known document extension on a typed name (`notes.docx` as plain text is `notes.txt`). An export the system dialog's name makes impossible (Word XML over an existing `.xml`) is refused on the Export page itself, not only the hidden status bar. Readiness estimates unchanged. - 2026-11-14: Review › Language: "Apply to the whole document" sets the proofing language or Do not check spelling for every story (body, headers, footers, notes, comments, text boxes, table cells, glossary) in one undo step, selection unchanged; `review.language` takes `scope: "document"`, default `selection` (#3518). Readiness estimates unchanged. - 2026-11-12: DOCX: `w:lnNumType` without a positive `w:countBy` leaves line numbering off, as Word does, instead of numbering every line on screen, in PDF export and on re-save (#6209). Readiness estimates unchanged. diff --git a/crates/layout/src/flow.rs b/crates/layout/src/flow.rs index 4d0248a863..2c7cc5da12 100644 --- a/crates/layout/src/flow.rs +++ b/crates/layout/src/flow.rs @@ -351,13 +351,14 @@ impl<'a> Flow<'a> { let closes_page = pb.next_starts_page && self.p.section.is_some(); let need = height + if rp.keep_next && !closes_page { - next_first_line(ctx, self.block, self.width, 0, pb.next_starts_page, &mut ctx.counters.clone()) + next_first_line(ctx, self.block, self.laid_width, 0, pb.next_starts_page, &mut ctx.counters.clone()) } else { 0.0 }; // (Against the whole column: balanced columns grow to hold it.) - // With the 0.01 pt of slack the other fit checks take. - if pb.y + need > pb.bottom + 0.01 && !pb.fresh() && need <= pb.next_room(self.body_top) { + // With the 0.01 pt of slack the other fit checks take. Balancing from Word 2013's layout + // keeps the lines and the next paragraph together at the top of a column too (#6821). + if pb.y + need > pb.bottom + 0.01 && (!pb.fresh() || Self::strict_widow_control(ctx, pb)) && need <= pb.next_room(self.body_top) { pb.advance(self.block, self.body_top); pb.y += rp.space_before.min(0.0); return rp.space_before.min(0.0); @@ -365,6 +366,25 @@ impl<'a> Flow<'a> { before } + /// Balancing from Word 2013's layout, a paragraph that was moved to the top of a column by + /// the lines before it (not by `keep_together`) keeps its lines, or itself with the next + /// paragraph, together there too: asks again, and places the paragraph's floats again where it + /// ends up (#6821). + fn keep_again(&mut self, ctx: &mut Ctx, pb: &mut PageBuilder, rooms: Rooms) { + while self.l0 == 0 && (self.pl.rp.keep_lines || self.pl.rp.keep_next) && pb.fresh() && Self::strict_widow_control(ctx, pb) { + let (col, pages) = (pb.col, pb.pages.len()); + let before = self.keep_together(ctx, pb, rooms, 0.0); + if (pb.col, pb.pages.len()) == (col, pages) { + break; + } + // Reflow before testing the new column: wraps can change the paragraph's height. + let y0 = pb.y; + self.reanchor(ctx, pb, (y0, before), &[]); + self.anchor_y = y0 - before; + (self.rechecked, self.forced) = (false, Vec::new()); + } + } + /// The lines going into a new column (or page) were broken around the wrap areas where the /// paragraph started: break them again around this column's (the lines before stay as they /// were, and so do the paragraph's own floating objects), when they differ (#1374). @@ -490,25 +510,46 @@ impl<'a> Flow<'a> { /// The end of the lines on this page after widow/orphan control, and keeping the rows beside /// floating objects together. - fn settled_end(&self, pb: &PageBuilder, fit: &Fit) -> usize { + /// Also says whether, balancing from Word 2013's layout, widow/orphan control alone moved every + /// line back (the next column has them, #6821). + fn settled_end(&self, ctx: &Ctx, pb: &PageBuilder, fit: &Fit) -> (usize, bool) { let (n, l0, mut l1) = (self.n(), self.l0, fit.l1); - // Widow/orphan control (2-line minimum at either end). + // Widow/orphan control (2-line minimum at either end). Balancing the columns of a + // section's last page from Word 2013's layout (compatibility mode 15) applies it at the + // top of a column too, where moving on is no loss, and never leaves one line of a + // paragraph that goes on in the next column, even when the paragraph began in an earlier + // one (#6821). + let strict = Self::strict_widow_control(ctx, pb); if fit.forced.is_none() && l1 < n && self.pl.rp.widow_control && n >= 2 { - if l1 - l0 == 1 && l0 == 0 && !pb.fresh() { + if l1 - l0 == 1 && l0 == 0 && (!pb.fresh() || strict) { l1 = l0; // orphan: move the first line to the next page } else if n - l1 == 1 && (l1 - l0 >= 3 || (l0 > 0 && l1 - l0 >= 2)) { l1 -= 1; // widow: take one more line along - } else if n - l1 == 1 && l0 == 0 && l1 - l0 == 2 && !pb.fresh() { + } else if n - l1 == 1 && l0 == 0 && l1 - l0 == 2 && (!pb.fresh() || strict) { // Neither split of a three-line paragraph is allowed (two and a widow, or an // orphan and two): it moves whole, as in Word. l1 = l0; } + // One line of a continued paragraph, with more after it (what was left of two lines + // after the widow line went along included): the rest moves with it. + if strict && l0 > 0 && l1 - l0 == 1 && l1 < n { + l1 = l0; + } } + let moved_on = strict && fit.l1 > l0 && l1 == l0; // A row (text both sides of a floating object) stays together. while l1 > l0 && l1 < n && self.pl.lines.get(l1).is_some_and(|l| l.beside) { l1 -= 1; } - l1 + (l1, moved_on) + } + + /// Whether the columns of this page are being balanced (`balance_columns`) and the document + /// has Word 2013's layout: Word then keeps the lines of a paragraph together that widow or + /// orphan control would split, at the top of a column as anywhere (#6821). Before compatibility + /// mode 15 it splits them. + fn strict_widow_control(ctx: &Ctx, pb: &PageBuilder) -> bool { + ctx.doc.settings.compat_mode >= 15 && !pb.relaxed && pb.balance.is_some_and(|(page, _)| page + 1 == pb.pages.len()) } /// Nothing fits on this page: move to the next column or page, and place the floats again @@ -669,16 +710,16 @@ impl<'a> Flow<'a> { } } - /// Late floats placed for lines that went on after all (past `l1`) wait for the next piece; - /// one whose own wrap pushed its line on stays, as before. Whether the lines from `l0` are to - /// be broken again without them. Does nothing once the wrap relays are used up + /// Late floats placed for lines past `l1` wait for the next piece. An overflow line keeps + /// its floats because it is still emitted here. Whether the lines from `l0` are to be broken + /// again without the released floats. Does nothing once the wrap relays are used up /// ([`MAX_WRAP_RELAYS`]). - fn settle_late(&mut self, pb: &mut PageBuilder, l1: usize) -> bool { + fn settle_late(&mut self, pb: &mut PageBuilder, l1: usize, overflow: bool) -> bool { let l0 = self.l0; if l0 == 0 || pb.web || self.late.placed.is_empty() || self.wrap_relays >= MAX_WRAP_RELAYS { return false; } - let end = if l1 == l0 && pb.fresh() { l0 + 1 } else { l1 }; // what the overflow keeps + let end = l1 + usize::from(overflow); let moved = self.late.release(self.p, &self.pl, end, &mut pb.excl) || self.late.keep_back(self.p, &self.pl, l0..end); moved && l1 > l0 } @@ -863,6 +904,7 @@ fn place_para_in_flow(ctx: &mut Ctx, pb: &mut PageBuilder, p: &Paragraph, block: f.anchor_y = y0 - applied_before; } while f.l0 < f.n() { + f.keep_again(ctx, pb, rooms); f.place_due_late(ctx, pb); f.relay_wrap(ctx, pb); f.relay_pages(ctx, pb); @@ -873,12 +915,20 @@ fn place_para_in_flow(ctx: &mut Ctx, pb: &mut PageBuilder, p: &Paragraph, block: let lead = if f.l0 == 0 { first.top.max(0.0) + rooms.top } else { 0.0 }; let notes = para_notes(ctx.doc, p, &f.pl); let mut fit = f.fit_lines(ctx, pb, ¬es, lead); - fit.l1 = f.settled_end(pb, &fit); - if f.settle_late(pb, fit.l1) { + let (end, widowed) = f.settled_end(ctx, pb, &fit); + fit.l1 = end; + // On a fresh column an unfitting line can overflow. Strict widow control instead moves + // the lines on without emitting anything and must release their late floats as well. + let overflow = end == f.l0 && pb.fresh() && !widowed; + if f.settle_late(pb, end, overflow) { continue; } if fit.l1 == f.l0 { - if !pb.fresh() { + // Balancing: widow/orphan control moved all the lines that fit on to the next column + // (or, short of room, the page after, which fails the try), where the lines of a + // column's first paragraph would otherwise overflow it. Lines pushed back for a row + // beside a floating object keep the overflow as before. + if !overflow { f.move_on(ctx, pb); continue; } @@ -1088,3 +1138,85 @@ fn next_first_line(ctx: &mut Ctx, block: usize, width: f32, depth: usize, new_pa None => 0.0, } } + +#[cfg(test)] +mod tests { + use super::*; + use wordcraft_doc::Pos; + use wordcraft_doc::para::{Anchor, Float, LINE_BREAK, Wrap, WrapText}; + use wordcraft_doc::props::LineSpacing; + + #[test] + fn strict_balancing_remeasures_kept_lines_in_the_next_column() { + crate::test_fonts(); + let mut doc = Document::new(); + doc.settings.compat_mode = 15; + doc.last_section.columns.count = 2; + let mut p = Paragraph::with_text("One two three four five six", Default::default()); + p.props.line_spacing = Some(LineSpacing::Exactly(14.0)); + p.props.keep_lines = Some(true); + doc.body = vec![wordcraft_doc::para_block(p)]; + let p = doc.body[0].as_para().unwrap(); + + crate::pass::with_flow_page(&doc, |ctx, pb| { + let top = pb.top; + pb.balance = Some((0, 28.1)); + pb.cap_columns(); + // A preceding floating object leaves a narrow strip of the first column, but does + // not occupy the second column. The same kept paragraph fits there in one line. + pb.excl.push((Rect::new(pb.col_x(), top, pb.col_w() - 26.0, 100.0), false, None, WrapText::BothSides, false)); + place_para_in_flow(ctx, pb, p, 0, top); + + assert_eq!(pb.pages.len(), 1, "a fitting candidate kept the balance attempt on its page"); + assert_eq!(pb.col, 1); + assert!( + pb.pages[0] + .items + .iter() + .any(|item| { matches!(item, Placed::Lines { x, l0: 0, l1: 1, story: StoryRef::Body, .. } if (*x - pb.col_x()).abs() < 0.01) }) + ); + }); + } + + #[test] + fn strict_widow_control_releases_a_late_float_when_no_line_is_emitted() { + crate::test_fonts(); + let mut doc = Document::new(); + doc.settings.compat_mode = 15; + doc.last_section.columns.count = 2; + let mut p = Paragraph::with_text(&format!("First{LINE_BREAK}Second{LINE_BREAK}Third"), Default::default()); + p.props.line_spacing = Some(LineSpacing::Exactly(14.0)); + p.props.widow_control = Some(true); + doc.body = vec![wordcraft_doc::para_block(p)]; + let anchor = Pos::body(0, "First".len() + LINE_BREAK.len_utf8()); + let float = Float { wrap: Wrap::Square, h_rel: Anchor::Column, v_rel: Anchor::Paragraph, ..Default::default() }; + doc.insert_object(&anchor, crate::tests::rect_shape(20.0, 20.0, float), &Default::default()).unwrap(); + let p = doc.body[0].as_para().unwrap(); + + crate::pass::with_flow_page(&doc, |ctx, pb| { + let top = pb.top; + let height = 14.1; + pb.advance(0, top); // start in the last column of the previous page + pb.bottom = top + height; + pb.balance = Some((1, height)); + let mut flow = Flow::new(ctx, pb, p, (0, top)); + assert!(pb.excl.is_empty(), "the float waits for its anchor line"); + + // Continue after the first line. The balance attempt can fit only one of the two lines left. + flow.l0 = 1; + pb.advance(0, top); + assert!(pb.fresh()); + assert!((pb.bottom - pb.top - height).abs() < 0.01); + flow.place_due_late(ctx, pb); + assert_eq!(pb.excl.len(), 1, "the anchor line fits before widow control"); + + let fit = flow.fit_lines(ctx, pb, &[], 0.0); + assert_eq!(fit.l1, 2); + let (end, widowed) = flow.settled_end(ctx, pb, &fit); + assert_eq!((end, widowed), (1, true)); + let overflow = end == flow.l0 && pb.fresh() && !widowed; + assert!(!flow.settle_late(pb, end, overflow)); + assert!(pb.excl.is_empty(), "no text is emitted here, so no wrap area may remain here"); + }); + } +} diff --git a/crates/layout/src/page.rs b/crates/layout/src/page.rs index 130a08bf07..565f00773e 100644 --- a/crates/layout/src/page.rs +++ b/crates/layout/src/page.rs @@ -71,6 +71,9 @@ pub(crate) struct PageBuilder<'a> { /// Balancing columns: (page index, column height) — that page's columns end `height` below /// the top of the section on it. pub(crate) balance: Option<(usize, f32)>, + /// Balancing without the strict widow/orphan and keep rules of Word 2013's layout (#6821): the + /// last try when even the full column height does not hold the text with them. + pub(crate) relaxed: bool, /// The page with the last explicit column break. pub(crate) col_break_page: Option, /// The section's footnotes go right below its text, not at the page bottom ... diff --git a/crates/layout/src/pass.rs b/crates/layout/src/pass.rs index af5bc8a8e0..c66272dc51 100644 --- a/crates/layout/src/pass.rs +++ b/crates/layout/src/pass.rs @@ -225,6 +225,7 @@ fn new_page_builder<'p>( max_y: 0.0, content_bottom: 0.0, balance: None, + relaxed: false, col_break_page: None, sect_beneath: false, beneath: false, @@ -236,6 +237,18 @@ fn new_page_builder<'p>( } } +#[cfg(test)] +pub(super) fn with_flow_page(doc: &Document, test: impl FnOnce(&mut Ctx<'_>, &mut PageBuilder<'_>)) { + let mut cache = LayoutCache::new(); + let opts = LayoutOptions::default(); + let mut ctx = new_ctx(doc, &mut cache, &opts, (&HashMap::new(), None, &Totals::first_guess(1))); + let sect = &doc.last_section; + let early = EarlyFloats::new(); + let mut page = new_page_builder(sect, sect.page_num_format, &early, false, false); + page.new_page(0, sect.margin_top); + test(&mut ctx, &mut page); +} + /// Endnotes in document order, with the section of their reference; placed at the end of a /// section that keeps them there, else at the end of the document. fn endnote_queue(ctx: &Ctx) -> VecDeque<(u32, usize)> { @@ -694,7 +707,9 @@ fn balance_pass<'a>( (page, top, h): (usize, f32, f32), body_top: f32, ) -> bool { + let relaxed = pb.relaxed; snap.restore(pb, ctx); + pb.relaxed = relaxed; pb.balance = Some((page, h)); pb.cap_columns(); for block in first..end { @@ -773,13 +788,26 @@ fn balance_columns<'a>(ctx: &mut Ctx, pb: &mut PageBuilder<'a>, blocks: (usize, last = Some((mid, ok)); } // End on the best height (the full column, as laid out first, when none was shorter). + let mut fits = true; if last != Some((hi, true)) { thrown = discard(ctx); - if !pass(ctx, pb, hi) && hi < full { + fits = pass(ctx, pb, hi); + if !fits && hi < full { thrown = discard(ctx); - pass(ctx, pb, full); + fits = pass(ctx, pb, full); } } + // From Word 2013's layout the strict widow/orphan and keep rules (`Flow::strict_widow_control`) + // can push text past even the full column (on a page whose columns are only a couple of lines + // high, where moving a line on to the next column never helps). The layout first made, without + // them, always fit it, so lay the page out as it was then rather than leave the pass that + // spilled to a new page. + if !fits { + thrown = discard(ctx); + pb.relaxed = true; + pass(ctx, pb, full); + pb.relaxed = false; + } thrown } diff --git a/crates/layout/src/tests.rs b/crates/layout/src/tests.rs index 04b0156c54..b9eba13e32 100644 --- a/crates/layout/src/tests.rs +++ b/crates/layout/src/tests.rs @@ -5,6 +5,7 @@ use wordcraft_doc::props::{Align, Border, BorderStyle, Borders, ParaProps, TextD use wordcraft_doc::{Pos, Table}; mod autospace; +mod balanced_tail; mod bidi; mod budget; mod cell_floats; diff --git a/crates/layout/src/tests/balanced_tail.rs b/crates/layout/src/tests/balanced_tail.rs new file mode 100644 index 0000000000..14f4b85787 --- /dev/null +++ b/crates/layout/src/tests/balanced_tail.rs @@ -0,0 +1,376 @@ +//! The last page of a section whose columns are balanced before a continuous break, when it holds +//! only the end of a paragraph that began on the page before, or a whole paragraph of two or three +//! lines (#6821). Measured in Word for Windows with exact 14 pt lines and no spacing, in three and +//! in two columns, one case per document, saved as compatibility mode 15 and as 14: from mode 15 +//! Word keeps such lines together in the first column that can hold them (the later columns may be +//! left short or empty), keeps a paragraph with "keep lines together" or "keep with next" whole +//! there when those rules fit, including in a section that starts and ends on one page. In mode +//! 14 Word splits two lines one per column. Synthetic tests also cover a footnote and a floating +//! picture. Mode 14's other layouts (a three-line tail, two and one; the text after the section) +//! and keep with next on the last lines of a paragraph that began on the page before remain open. +use crate::*; +use wordcraft_doc::para::{Anchor, Float, InlineObject, NoteKind, ShapeKind, Wrap}; +use wordcraft_doc::props::{LineSpacing, ParaProps}; +use wordcraft_doc::section::{SectionProps, SectionStart}; +use wordcraft_doc::{PartKind, Pos, para_block}; + +const LINE: f32 = 14.0; + +fn lay(doc: &Document) -> DocLayout { + let mut c = LayoutCache::new(); + layout(doc, &mut c, &LayoutOptions::default()) +} + +fn para_with(text: &str, keep_lines: bool, keep_next: bool) -> Arc { + let chr = wordcraft_doc::CharProps { font: Some("Source Sans 3".into()), size: Some(12.0), ..Default::default() }; + let mut p = Paragraph::with_text(text, chr); + p.props = ParaProps { + space_before: Some(0.0), + space_after: Some(0.0), + line_spacing: Some(LineSpacing::Exactly(LINE)), + keep_lines: keep_lines.then_some(true), + keep_next: keep_next.then_some(true), + ..Default::default() + }; + para_block(p) +} + +fn para(text: &str) -> Arc { + para_with(text, false, false) +} + +/// A paragraph of `k` lines, each ended by a line break: "P1", "P2"… +fn lines_text(k: usize) -> String { + (1..=k).map(|i| format!("P{i}")).collect::>().join(&wordcraft_doc::para::LINE_BREAK.to_string()) +} + +#[derive(Clone, Copy, PartialEq)] +enum Keep { + No, + Lines, + Next, +} + +/// What follows the filler paragraphs: a paragraph of `k` lines ("P1"…), then optionally one more +/// line ("Q1"), all in `cols` columns, then "After" in one column. +#[derive(Clone, Copy)] +struct Case { + cols: u32, + /// How many one-line paragraphs come first, relative to the lines on a page: `-3` leaves room + /// for three lines of the paragraph, `0` starts the paragraph on the next page, `1` puts one + /// more line before it there. With `intro` it is the plain number of them. + from_page_end: i32, + k: usize, + q: bool, + compat: u32, + /// A footnote referenced at the end of the paragraph. + note: bool, + /// A floating 28 pt tall picture-sized shape anchored in "Q1" (needs `q`). + float: Option, + /// This many lines of text and a one-column section break before the columns: the section + /// starts mid-page and ends on the same page. + intro: usize, + /// Columns closed by a continuous break (balanced) or running to the end of the document. + balanced: bool, + keep: Keep, + /// A page of this many lines of text (for a page too short for the rules). + page_lines: Option, +} + +impl Case { + fn new(cols: u32, from_page_end: i32, k: usize) -> Case { + Case { cols, from_page_end, k, q: false, compat: 15, note: false, float: None, intro: 0, balanced: true, keep: Keep::No, page_lines: None } + } +} + +/// The document of a case, the index of the `k`-line paragraph and of "Q1", and the offsets of the +/// paragraph's lines. +fn build(c: &Case) -> (Document, usize, Option, Vec) { + crate::test_fonts(); + let mut d = Document::new(); + d.settings.compat_mode = c.compat; + let mut s = SectionProps { start: SectionStart::Continuous, ..Default::default() }; + s.columns.count = c.cols; + if let Some(n) = c.page_lines { + s.page_h = s.margin_top + s.margin_bottom + n as f32 * LINE + 0.5; + d.last_section.page_h = s.page_h; + } + let per_col = ((s.page_h - s.margin_top - s.margin_bottom) / LINE).floor() as i32; + let fillers = if c.intro > 0 { c.from_page_end.max(0) } else { (per_col * c.cols as i32 + c.from_page_end).max(0) } as usize; + let mut body: Vec> = (0..c.intro).map(|i| para(&format!("i{i}"))).collect(); + if c.intro > 0 { + let mut one = SectionProps { start: SectionStart::Continuous, ..Default::default() }; + one.columns.count = 1; + let mut mark = para(""); + if let Block::Para(p) = Arc::make_mut(&mut mark) { + p.section = Some(Box::new(one)); + } + body.push(mark); + } + body.extend((0..fillers).map(|i| para(&format!("r{i}")))); + let first = body.len(); + let text = lines_text(c.k); + body.push(para_with(&text, c.keep == Keep::Lines, c.keep == Keep::Next)); + let q = c.q.then_some(body.len()); + if c.q { + body.push(para("Q1")); + } + let mark = body.len(); + if c.balanced { + body.push(para("")); + body.push(para("After")); + } + d.body = body; + if c.balanced { + if let Some(Block::Para(p)) = d.body.get_mut(mark).map(Arc::make_mut) { + p.section = Some(Box::new(s)); + } + d.last_section.start = SectionStart::Continuous; + } else { + d.last_section.columns.count = c.cols; + } + if let (Some(w), Some(qi)) = (c.float, q) { + let float = Float { wrap: w, h_rel: Anchor::Column, v_rel: Anchor::Paragraph, x: 0.0, y: 0.0, ..Default::default() }; + let shape = InlineObject::Shape { + kind: ShapeKind::Rectangle, + w: if w == Wrap::TopAndBottom { 100.0 } else { 60.0 }, + h: 28.0, + fill: None, + stroke: None, + stroke_width: 1.0, + float, + story: None, + freeform: None, + effects: Default::default(), + extra: Default::default(), + }; + d.insert_object(&Pos::body(qi, 0), shape, &Default::default()).unwrap(); + } + let breaks = text.char_indices().filter(|(_, ch)| *ch == wordcraft_doc::para::LINE_BREAK); + let starts: Vec = std::iter::once(0).chain(breaks.map(|(i, ch)| i + ch.len_utf8())).collect(); + if c.note { + let id = d.add_part(PartKind::Footnote, vec![para("Note")]); + let end = text.len(); + d.insert_object(&Pos::body(first, end), InlineObject::NoteRef { kind: NoteKind::Footnote, id, custom: String::new() }, &Default::default()) + .unwrap(); + } + (d, first, q, starts) +} + +/// The columns of the lines of the `k`-line paragraph (counted from the left, 0 to `cols - 1`), +/// of "Q1" if there is one, and the number of pages. +fn columns(c: &Case) -> (Vec, Option, usize) { + let (d, first, q, starts) = build(c); + let l = lay(&d); + let carets: Vec<_> = starts.iter().map(|&o| l.caret(&Pos::body(first, o)).unwrap()).collect(); + let q_caret = q.map(|qi| l.caret(&Pos::body(qi, 0)).unwrap()); + // The columns' left edges, from the section's declared geometry so that an empty column keeps + // its place. A line beside a float starts right of its column's edge, so a position is in the + // last edge at or left of it. + let sp = SectionProps::default(); + let n = c.cols.max(1); + let width = (sp.page_w - sp.margin_left - sp.margin_right - sp.gutter - sp.columns.space * (n - 1) as f32) / n as f32; + let xs: Vec = (0..n).map(|i| sp.margin_left + i as f32 * (width + sp.columns.space)).collect(); + let col = |x: f32| xs.iter().rposition(|e| *e <= x + 1.0).unwrap_or(usize::MAX); + (carets.iter().map(|c| col(c.x)).collect(), q_caret.map(|c| col(c.x)), l.pages.len()) +} + +fn of(c: &Case) -> Vec { + columns(c).0 +} + +// A: the last two lines of a paragraph whose first three lines closed the page before. +#[test] +fn the_last_two_lines_of_a_continued_paragraph_stay_in_the_first_column() { + for cols in [3, 2] { + let (v, _, pages) = columns(&Case::new(cols, -3, 5)); + assert_eq!(pages, 2, "{cols} columns"); + assert_eq!(v[3..], [0, 0], "{cols} columns: lines 4 and 5 together"); + } +} + +// B: three lines stay together too: not two and one, nor one and two. +#[test] +fn the_last_three_lines_of_a_continued_paragraph_stay_in_the_first_column() { + for cols in [3, 2] { + assert_eq!(of(&Case::new(cols, -3, 6))[3..], [0, 0, 0], "{cols} columns"); + } +} + +// L: five lines are three and two (not two, one and two). +#[test] +fn the_last_five_lines_of_a_continued_paragraph_are_three_and_two() { + for cols in [3, 2] { + assert_eq!(of(&Case::new(cols, -3, 8))[3..], [0, 0, 0, 1, 1], "{cols} columns"); + } +} + +// N: a one-line paragraph after the two lines goes to the second column. +#[test] +fn a_line_after_the_continued_two_lines_goes_to_the_next_column() { + for cols in [3, 2] { + let (v, q, _) = columns(&Case { q: true, ..Case::new(cols, -3, 5) }); + assert_eq!((v[3..].to_vec(), q), (vec![0, 0], Some(1)), "{cols} columns"); + } +} + +// K, E: a paragraph of three lines (or two) that begins the last page stays together. +#[test] +fn a_whole_paragraph_of_two_or_three_lines_at_the_top_of_the_last_page_stays_together() { + for cols in [3, 2] { + assert_eq!(of(&Case::new(cols, 0, 3)), [0, 0, 0], "{cols} columns, three lines"); + assert_eq!(of(&Case::new(cols, 0, 2)), [0, 0], "{cols} columns, two lines"); + } +} + +// K2: the same after one line of another paragraph in the first column: it starts the second. +#[test] +fn a_three_line_paragraph_after_one_line_on_the_last_page_stays_together() { + for cols in [3, 2] { + let (v, _, pages) = columns(&Case::new(cols, 1, 3)); + assert_eq!((v, pages), (vec![1, 1, 1], 2), "{cols} columns"); + } +} + +// F: with a footnote on the last page, referenced at the end of the paragraph. +#[test] +fn a_footnote_on_the_last_page_leaves_the_tail_together() { + for cols in [3, 2] { + let n = |off, k| of(&Case { note: true, ..Case::new(cols, off, k) }); + assert_eq!(n(-3, 5)[3..], [0, 0], "{cols} columns, two lines"); + assert_eq!(n(-3, 6)[3..], [0, 0, 0], "{cols} columns, three lines"); + assert_eq!(n(0, 2), [0, 0], "{cols} columns, whole paragraph of two lines"); + assert_eq!(n(0, 3), [0, 0, 0], "{cols} columns, whole paragraph of three lines"); + } +} + +// L2: beside a square-wrapped float in the next paragraph; a top-and-bottom one is the guard. +#[test] +fn a_square_wrapped_float_after_the_tail_leaves_it_together() { + for cols in [3, 2] { + let sq = |off, k| columns(&Case { q: true, float: Some(Wrap::Square), ..Case::new(cols, off, k) }); + let (v, q, _) = sq(-3, 5); + assert_eq!((v[3..].to_vec(), q), (vec![0, 0], Some(1)), "{cols} columns, two lines"); + let (v, q, _) = sq(0, 3); + assert_eq!((v, q), (vec![0, 0, 0], Some(1)), "{cols} columns, whole paragraph of three lines"); + } +} + +#[test] +fn a_top_and_bottom_float_after_the_tail_is_laid_out_as_before() { + for cols in [3, 2] { + let tb = |off, k| columns(&Case { q: true, float: Some(Wrap::TopAndBottom), ..Case::new(cols, off, k) }); + let (v, q, _) = tb(-3, 5); + assert_eq!((v[3..].to_vec(), q), (vec![0, 0], Some(1)), "{cols} columns, two lines"); + let (v, q, _) = tb(0, 3); + assert_eq!((v, q), (vec![0, 0, 0], Some(1)), "{cols} columns, whole paragraph of three lines"); + } +} + +// M: a section that starts and ends on one page (after two lines of text in one column). +#[test] +fn a_five_line_paragraph_balanced_mid_page_is_three_and_two() { + assert_eq!(of(&Case { intro: 2, ..Case::new(3, 0, 5) }), [0, 0, 0, 1, 1]); +} + +#[test] +fn a_section_balanced_mid_page_is_laid_out_as_before() { + let mid = |cols, filler, k| of(&Case { intro: 2, ..Case::new(cols, filler, k) }); + assert_eq!(mid(3, 0, 2), [0, 0]); + assert_eq!(mid(3, 0, 3), [0, 0, 0]); + assert_eq!(mid(3, 0, 4), [0, 0, 1, 1]); + assert_eq!(mid(3, 0, 6), [0, 0, 1, 1, 2, 2]); + assert_eq!(mid(2, 0, 3), [0, 0, 0]); + assert_eq!(mid(2, 0, 5), [0, 0, 0, 1, 1]); + assert_eq!(mid(2, 0, 6), [0, 0, 0, 1, 1, 1]); + // After one more line. + assert_eq!(mid(3, 1, 3), [1, 1, 1]); + assert_eq!(mid(3, 1, 4), [1, 1, 2, 2]); + assert_eq!(mid(3, 1, 5), [0, 0, 1, 1, 1]); + assert_eq!(mid(2, 1, 4), [0, 0, 1, 1]); + assert_eq!(mid(2, 1, 6), [0, 0, 0, 1, 1, 1]); +} + +// X: keep lines together, and keep with next, hold the paragraph whole in the first column. +#[test] +fn a_paragraph_kept_together_stays_whole_in_the_first_balanced_column() { + for cols in [3, 2] { + let kept = |off, k| of(&Case { keep: Keep::Lines, ..Case::new(cols, off, k) }); + assert_eq!(kept(0, 3), [0, 0, 0], "{cols} columns, three lines at the top"); + // Keep lines together moved it whole onto the last page. + assert_eq!(kept(-3, 5), [0, 0, 0, 0, 0], "{cols} columns, five lines"); + assert_eq!(kept(-3, 6), [0, 0, 0, 0, 0, 0], "{cols} columns, six lines"); + } +} + +#[test] +fn a_paragraph_kept_with_the_next_stays_with_it_in_the_first_balanced_column() { + for cols in [3, 2] { + let (v, q, _) = columns(&Case { keep: Keep::Next, q: true, ..Case::new(cols, 0, 3) }); + assert_eq!((v, q), (vec![0, 0, 0], Some(0)), "{cols} columns"); + } +} + +// Guards, the same in Word and before the change. + +// C, M: four lines are two and two, six are two, two and two. +#[test] +fn longer_tails_are_balanced_as_before() { + for cols in [3, 2] { + assert_eq!(of(&Case::new(cols, -3, 7))[3..], [0, 0, 1, 1], "{cols} columns, four lines"); + } + assert_eq!(of(&Case::new(3, -3, 9))[3..], [0, 0, 1, 1, 2, 2], "three columns, six lines"); +} + +// O: a four-line paragraph that begins the last page is two and two. +#[test] +fn a_four_line_paragraph_at_the_top_of_the_last_page_is_two_and_two() { + for cols in [3, 2] { + assert_eq!(of(&Case::new(cols, 0, 4)), [0, 0, 1, 1], "{cols} columns"); + } +} + +// Columns not balanced (nothing follows them): the lines are not split without need. +#[test] +fn unbalanced_columns_keep_the_tail_in_the_first_column() { + for cols in [3, 2] { + let c = Case { balanced: false, ..Case::new(cols, -3, 5) }; + assert_eq!(of(&c)[3..], [0, 0], "{cols} columns"); + } +} + +// Before Word 2013's layout (mode 14) the two lines are split one per column, as Word does. +#[test] +fn mode_14_still_splits_the_last_two_lines_of_a_continued_paragraph() { + for cols in [3, 2] { + let c = Case { compat: 14, ..Case::new(cols, -3, 5) }; + assert_eq!(of(&c)[3..], [0, 1], "{cols} columns"); + } +} + +/// How many lines of body text are laid out, and on how many pages. +fn shape(c: &Case) -> (usize, usize) { + let (d, ..) = build(c); + let l = lay(&d); + let lines = l + .pages + .iter() + .flat_map(|p| p.items.iter()) + .map(|it| match it { + Placed::Lines { story: StoryRef::Body, l0, l1, .. } => l1 - l0, + _ => 0, + }) + .sum(); + (l.pages.len(), lines) +} + +// A page whose columns hold two lines is too short for the rules that keep three lines together: +// not even the full column holds the paragraph with them, so the columns are laid out as before +// (mode 14), with every line placed and no more pages. +#[test] +fn a_page_too_short_for_the_strict_rules_is_laid_out_as_in_mode_14() { + let tiny = |compat| Case { compat, page_lines: Some(2), ..Case::new(2, 0, 3) }; + let (pages, lines) = shape(&tiny(14)); + assert!(lines >= 4, "the paragraph's three lines and After: {lines}"); + assert_eq!(shape(&tiny(15)), (pages, lines)); +} diff --git a/docs/gaps.md b/docs/gaps.md index ffabd917f4..a15a48b359 100644 --- a/docs/gaps.md +++ b/docs/gaps.md @@ -2,7 +2,7 @@ > **CLI path update:** 2026-11-04 · Options before a non-Unicode input filename no longer make the CLI reject that filename; text option values still require Unicode; `run --file` and `run --script` retain native paths. No ranked gap or readiness estimate changes. -> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-21 · **Change:** trivial (table rows split across pages: a cell's first paragraph on the page can split even when only one line fits, if the row starts at the top, with or without its own headers, or continues from the previous page (#6823)); previously trivial (gap #4: legacy header lines stay in place around narrow Square, Tight and Through logos, #6805); previously trivial (PDF exports, print jobs and page images mark tracked changes in the Track Changes Options colours and marks, print jobs without Print Markup lay out the final text, and the print preview and downloaded PNGs draw headers at full strength, #5232, #6267; no ranked gap changed); previously trivial (formatting shortcuts say what they did to screen readers); previously trivial (dialogs are dialogs to screen readers, their tabs are tabs, and colour fields and swatches say their colour); previously trivial (the Paste button is named "Paste" for screen readers, without macOS's key on other platforms; the status bar's Go To hint shows the platform's key); previously trivial (#4: a missing font its publisher gives away names the download page (`font.missing`, Get the Missing Fonts)); previously trivial (gap 4: Word 2003's indent rules beside floating objects, #5939); previously trivial (#5: a list item deleted whole under Track Changes shows its number as deleted text, #4828); previously trivial (clipboard: a copied picture now reaches the system clipboard as PNG, with HTML where the host writes it; a copy of only shapes still stays in WordCraft, #6205); previously trivial (#4501 refactor regressions restored, #4683; no ranked gap changed); previously trivial (#19: ODT default language kept when styles are written from the model); previously trivial (#10 narrowed: a turned inline picture whose file keeps no room for the turn keeps its line to its frame, as in Word); previously trivial (Protected typing boundary lookup counts preceding objects once and indexes editable permission IDs (#3614); caret movement and enforcement policy are unchanged; previously trivial: View windows: several open documents and Switch Windows in the engine; previously trivial: explicit documents keep the editor when recovery discovery finishes; readable recovery controls; previously trivial: text mini toolbar available with the right-click menu, #2959; previously trivial: personal templates in File › New and Save as Word Template, #2852; previously trivial: tracked table/row/cell/section property changes record in WordCraft, narrowing gap 5; previously trivial: a document with many content controls saves in the time the controls take, #13; previously trivial: Format Page Numbers dialog carries Word's number formats and Continue from previous section / Start at, #1113; previously trivial: centred list labels after leading page breaks, #2964; previously trivial: fixed font inputs in four layout controls; previously trivial: a right, centre or decimal tab whose text doesn't fit, or a left tab past the right indent, goes to the next line with its text, #1840; previously trivial: Bullets and Numbering toggle off style-inherited lists at their effective level, including basedOn chains and numbered ListParagraph styles; other paragraphs and list definitions stay unchanged (related to #3459); previously trivial (gap 4: a float anchored right after a page break, before text, is drawn on the new page, #4262); previously trivial (Drawing Canvas members picked and moved on their own, #2637); previously trivial (gap 4: a float anchored on a later page of a long paragraph is drawn there, #4250); previously trivial (#29: typed `\int`, `\sum`… + Space wait for their limits, observed in Word for Windows on #4938, #4917); previously trivial (only the PDF sent to the printer leaves out link annotations; Save these pages as PDF keeps them, #4734; no ranked gap changed); previously trivial (print helpers erase loaded plaintext inputs before driver work, #5710); previously trivial (Windows print submissions use isolated helpers so a cancelled driver cannot block a retry, #5710); previously trivial (print cancellation remains available without a document; sending-boundary limitation clarified, #5710); previously trivial (gap 6: a print job waiting on its driver can be cancelled, #5710; no ranked gap changed); previously trivial (gap 6: the printer list no longer waits on printer drivers, #5710; no ranked gap changed); previously trivial (Page drawing indexes text-box warp lookups per paragraph (#3614)); previously trivial (built-in citation source lookups, #4888; current-main progress records retained); previously trivial (MATH construction reuse, #3630); previously trivial (DOCX `w:adjustRightInd` defaults true and is written in schema order); previously trivial (ink page lookups reuse scanned paragraph prefixes, #3614); previously trivial (#19: ODT settings for what the standard leaves open removed); previously trivial (#19: ODT element audit; files from other applications checked); previously trivial (#11: the dialogs of the mirrored Arabic interface read right to left: label-and-field rows, tables (list columns, the Models table), tile galleries and the Add/Remove arrows follow the reading direction, through one `rtl::Table` helper that draws exactly as before in English; no ranked gap closed, readiness estimates unchanged); previously trivial (#4: fonts that aren't installed are flagged in the font box and status bar); previously trivial (#19: ODT sections inside text boxes kept as read); previously trivial (#19: an ODT saved without edits keeps what WordCraft doesn't model); previously trivial (#19: ODT interpretation profile, WordCraft / LibreOffice / custom); previously trivial (#19: ODT form controls placed and multi-line; custom shapes keep their geometry); previously trivial (#19: ODT in-line frames placed against the text; template instantiation listed as left); previously trivial (#19: ODT charts kept as read; frame outlines; default header height); previously trivial (#19: ODT tables no longer gain repeated header rows); previously trivial (#19: ODT padding without a border, unequal columns, column breaks, picture-only lines); previously trivial (#19: ODT tables' margins and spacing, header spacing, pictures alone in a paragraph); previously trivial (#19: no LibreOffice template changes page count through a save); previously trivial (#19: ODT variables, emphasis marks, page backgrounds, fixed tables, default size); previously trivial (#19: ODT checked against LibreOffice's own templates: placeholders, first-page styles, unsized pages, metafile logos, `.ott`); previously trivial (#19: ODT at ~90%: custom shapes, cell formulas, macros kept, turned text, control sizes and buttons); previously trivial (#19 narrowed: ODT read and written nearly whole; estimate 18–27 h → 10–16 h); previously trivial (#10 narrowed: text in a turned text box is drawn turned with it); previously trivial (gap 19 narrowed: ODT heading numbering read and written); previously trivial (gap 19 narrowed: ODT table borders and padding read and written); previously trivial (gap 19 narrowed: ODT heading style looks read and written); previously trivial (gap 19 narrowed: ODT tab stops read and written); previously trivial (gap 19 narrowed: ODT character formatting read and written); previously trivial (gap 19 narrowed: ODT list formats read and written); previously trivial (gap 19 narrowed: ODT comments read and written); previously trivial (gap 19 narrowed: ODT footnotes and endnotes read and written); previously trivial (gap 19 narrowed: ODT headers and footers written, text fields and paragraph spacing read and written); previously trivial (#8: Options › Language lists Your languages and Add a language… replaces the Language packs table); previously trivial (#8: the missing-pack bar works on a fresh install and counts the caret's language); previously trivial (#8: Language pack languages are in Set Proofing Language, Review › Language and the status bar; built-in proofing is named as such); previously trivial (#20: layout resource caps and linear-time passes (#3867, #3866)); previously trivial (#3 narrowed: a pasted text box story is charged for the formatting it copies); previously trivial (#3 narrowed: a .doc table row keeps one override per cell); previously trivial (#3 narrowed: a .doc file's sections find their paragraphs by index); previously minor (#11: Arabic interface with mirrored shell landed, #1195; hi/id/pt-PT and Hebrew UI remain); previously trivial (#8: language-packs-2 is published and pinned: 75 packs, adding Danish, German (Germany, Austria, Switzerland), Esperanto, Estonian, Persian, Croatian, Hungarian, Norwegian (Bokmål, Nynorsk), Dutch and Swedish (Sweden, Finland); no ranked gap changed); previously trivial (#8: language-packs-1 is published and pinned, 61 packs: Lithuanian, Romanian, Catalan, French, Greek, Slovak, Serbian and Latvian install as Language packs; Dutch, German and the other compounding languages wait on craft-proof; no ranked gap changed); previously minor (#8: Language packs: every other language's spelling and hyphenation installs from File › Options › Language or the missing-pack bar, through the font store; Lithuanian and Romanian are available as a Language pack once language-packs-1 is published; Dutch, Catalan, French, Greek, Slovak, Serbian and Latvian packs wait on craft-proof engine support); previously trivial (gap 8: English spelling reads SCOWL 2026, one dictionary per English, #40, #520, #5205; no ranked gap changed);; previously trivial (DOCX table rows and cells inside selected alternate-content branches survive open and repeated saves (#5219); broader corpus qualification and readiness estimates unchanged); previously trivial (#26 narrowed: MHT opens and `w:altChunk` content is brought in on open; saving MHT remains) previously trivial (gap 8 points at craft-proof in craft-libs, its data in craft-i18n, #5202; no ranked gap changed); previously trivial (arrowheads keep their kind, width and length and are drawn at Word's sizes; no ranked gap changed); previously trivial (.doc default font from the stylesheet's standard font, #5066; no ranked gap changed); previously trivial (a middle or bottom cell of a row split across pages lines up on the first page; no ranked gap changed); previously trivial (tab leader dots spaced and placed as in Word; no ranked gap changed); previously trivial (a list level above counts its first number at the first deeper item; no ranked gap changed); previously trivial (only the PDF sent to the printer leaves out link annotations; Save these pages as PDF keeps them, #4734; no ranked gap changed); previously trivial (documents with links print: the print job leaves out link annotations, #4734; no ranked gap changed; previously trivial: aligned-copy review fixes retain the document axis through scrolling and include secondary selections (#4764)); previously trivial (connector rerouting indexes laid-out object positions once per batch (#3631); previously trivial (custom-property bookmark-link preservation, #4767); previously trivial (Relative font-size commands preserve mixed sizes in the selection (#4903); existing button steps and one-point shortcuts are unchanged; readiness estimates unchanged); previously trivial (Arabic Backspace removes one combining mark and keeps its base letter (#4757); previously trivial (note conversion reference-run membership uses one ordered walk, #4750); previously trivial (DOCX comment-ID save lookups); previously trivial (gap 19: RTF reads and writes WMF and EMF pictures, #4259); previously trivial (#4658 bounds nested Markdown reference-label work); previously trivial (HTML import keeps preformatted lines with CR or CRLF input newlines, #4810); previously trivial (Recipient labels continue across product-sized sheets instead of stopping after the first sheet (#4880)); previously trivial (View windows: several open documents and Switch Windows in the engine; previously trivial: explicit documents keep the editor when recovery discovery finishes; readable recovery controls; previously trivial: text mini toolbar available with the right-click menu, #2959; previously trivial: personal templates in File › New and Save as Word Template, #2852; previously trivial: tracked table/row/cell/section property changes record in WordCraft, narrowing gap 5; previously trivial: a document with many content controls saves in the time the controls take, #13; previously trivial: Format Page Numbers dialog carries Word's number formats and Continue from previous section / Start at, #1113; previously trivial: centred list labels after leading page breaks, #2964; previously trivial: fixed font inputs in four layout controls; previously trivial: a right, centre or decimal tab whose text doesn't fit, or a left tab past the right indent, goes to the next line with its text, #1840; previously trivial: Bullets and Numbering toggle off style-inherited lists at their effective level, including basedOn chains and numbered ListParagraph styles; other paragraphs and list definitions stay unchanged (related to #3459); previously trivial: Russian sorting keeps ё with е and recognises decomposed ё/й; previously trivial: #8: English dialects — en-GB, en-CA, en-AU… flag each other's spellings, #1281; previously trivial: #1: shape gradients and transparency, #1500; previously trivial: text typed into a content control takes the control's formatting; localized placeholder styles recognised; previously trivial: forms protection keeps its content controls: no inserting, Properties or Remove Content Control; previously trivial: clearing a no-match font query keeps the recent heading visible, #2068; previously trivial: line breaking: a slash opening a word travels whole to the next line, #2963; previously trivial: recipient list search and merged-only view, #1576; previously trivial: #2 impact restated: only ink rendering and OLE editing remain; previously trivial: #2 narrowed: native ink nested in groups and drawing canvases kept on save; previously trivial: opening a DOCX no longer copies its pictures; previously trivial: RTF export writes sections (gap 19); previously trivial: ODT export writes sections (gap 19); previously trivial: automatic Asian/Latin and Asian/number spacing laid out, #2358; previously trivial: hint-reliant CJK outlines; previously trivial: numbered headings, #1793; previously trivial: legacy outline, shadow, emboss and imprint text effects drawn, #2534; previously trivial: #8 narrowed: Indonesian proofing from the installed Hunspell dictionary, #498; previously trivial: glossary/building blocks closed; previously trivial: Split Cells and Convert Text to Table follow the Word check, #2592; previously trivial: Language dialog keeps inherited proofing language and no-proof choices (#2717); previously trivial: #29: a copied equation also goes in the MathML clipboard formats, #1297; previously trivial: #24: the Spike, Ctrl+F3 and Ctrl+Shift+F3; previously trivial: VML freeforms read and kept on save; previously trivial: consistent preferred cell widths; previously trivial: multi-paragraph field instructions no longer add blank lines; previously trivial: page-break-only list paragraphs hide their labels; previously trivial: floating-table overlap ignores empty line-break lines; previously trivial: copies keep their formatting on the clipboard as HTML, #1523; previously trivial: sample-text formulas on Enter, #1067; previously trivial: #29: copied equations as MathML, OMML open as #1297, #816; previously trivial: the Font list no longer keeps every previewed font in memory, #848; previously trivial: table column and row markers on the rulers, #700; previously trivial: table borders and the resize handle drag on the page, #217; previously trivial: formatting revisions landed, #41; previously trivial: Draw Table and Eraser landed, #303; previously minor: beta distance restated: ~15 points, ~150–230 h; previously: first version; every known shortfall from the 2026-10-10 re-measure, ranked) · **Target:** Microsoft Word (Microsoft 365) for Mac 16.113.4 +> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-21 · **Change:** trivial (release wrap areas when strict column balancing moves the anchor line, #6821); previously trivial (balanced columns keep lines together from Word 2013's layout, #6821); previously trivial (table rows split across pages: a cell's first paragraph on the page can split even when only one line fits, if the row starts at the top, with or without its own headers, or continues from the previous page (#6823)); previously trivial (gap #4: legacy header lines stay in place around narrow Square, Tight and Through logos, #6805); previously trivial (PDF exports, print jobs and page images mark tracked changes in the Track Changes Options colours and marks, print jobs without Print Markup lay out the final text, and the print preview and downloaded PNGs draw headers at full strength, #5232, #6267; no ranked gap changed); previously trivial (formatting shortcuts say what they did to screen readers); previously trivial (dialogs are dialogs to screen readers, their tabs are tabs, and colour fields and swatches say their colour); previously trivial (the Paste button is named "Paste" for screen readers, without macOS's key on other platforms; the status bar's Go To hint shows the platform's key); previously trivial (#4: a missing font its publisher gives away names the download page (`font.missing`, Get the Missing Fonts)); previously trivial (gap 4: Word 2003's indent rules beside floating objects, #5939); previously trivial (#5: a list item deleted whole under Track Changes shows its number as deleted text, #4828); previously trivial (clipboard: a copied picture now reaches the system clipboard as PNG, with HTML where the host writes it; a copy of only shapes still stays in WordCraft, #6205); previously trivial (#4501 refactor regressions restored, #4683; no ranked gap changed); previously trivial (#19: ODT default language kept when styles are written from the model); previously trivial (#10 narrowed: a turned inline picture whose file keeps no room for the turn keeps its line to its frame, as in Word); previously trivial (Protected typing boundary lookup counts preceding objects once and indexes editable permission IDs (#3614); caret movement and enforcement policy are unchanged; previously trivial: View windows: several open documents and Switch Windows in the engine; previously trivial: explicit documents keep the editor when recovery discovery finishes; readable recovery controls; previously trivial: text mini toolbar available with the right-click menu, #2959; previously trivial: personal templates in File › New and Save as Word Template, #2852; previously trivial: tracked table/row/cell/section property changes record in WordCraft, narrowing gap 5; previously trivial: a document with many content controls saves in the time the controls take, #13; previously trivial: Format Page Numbers dialog carries Word's number formats and Continue from previous section / Start at, #1113; previously trivial: centred list labels after leading page breaks, #2964; previously trivial: fixed font inputs in four layout controls; previously trivial: a right, centre or decimal tab whose text doesn't fit, or a left tab past the right indent, goes to the next line with its text, #1840; previously trivial: Bullets and Numbering toggle off style-inherited lists at their effective level, including basedOn chains and numbered ListParagraph styles; other paragraphs and list definitions stay unchanged (related to #3459); previously trivial (gap 4: a float anchored right after a page break, before text, is drawn on the new page, #4262); previously trivial (Drawing Canvas members picked and moved on their own, #2637); previously trivial (gap 4: a float anchored on a later page of a long paragraph is drawn there, #4250); previously trivial (#29: typed `\int`, `\sum`… + Space wait for their limits, observed in Word for Windows on #4938, #4917); previously trivial (only the PDF sent to the printer leaves out link annotations; Save these pages as PDF keeps them, #4734; no ranked gap changed); previously trivial (print helpers erase loaded plaintext inputs before driver work, #5710); previously trivial (Windows print submissions use isolated helpers so a cancelled driver cannot block a retry, #5710); previously trivial (print cancellation remains available without a document; sending-boundary limitation clarified, #5710); previously trivial (gap 6: a print job waiting on its driver can be cancelled, #5710; no ranked gap changed); previously trivial (gap 6: the printer list no longer waits on printer drivers, #5710; no ranked gap changed); previously trivial (Page drawing indexes text-box warp lookups per paragraph (#3614)); previously trivial (built-in citation source lookups, #4888; current-main progress records retained); previously trivial (MATH construction reuse, #3630); previously trivial (DOCX `w:adjustRightInd` defaults true and is written in schema order); previously trivial (ink page lookups reuse scanned paragraph prefixes, #3614); previously trivial (#19: ODT settings for what the standard leaves open removed); previously trivial (#19: ODT element audit; files from other applications checked); previously trivial (#11: the dialogs of the mirrored Arabic interface read right to left: label-and-field rows, tables (list columns, the Models table), tile galleries and the Add/Remove arrows follow the reading direction, through one `rtl::Table` helper that draws exactly as before in English; no ranked gap closed, readiness estimates unchanged); previously trivial (#4: fonts that aren't installed are flagged in the font box and status bar); previously trivial (#19: ODT sections inside text boxes kept as read); previously trivial (#19: an ODT saved without edits keeps what WordCraft doesn't model); previously trivial (#19: ODT interpretation profile, WordCraft / LibreOffice / custom); previously trivial (#19: ODT form controls placed and multi-line; custom shapes keep their geometry); previously trivial (#19: ODT in-line frames placed against the text; template instantiation listed as left); previously trivial (#19: ODT charts kept as read; frame outlines; default header height); previously trivial (#19: ODT tables no longer gain repeated header rows); previously trivial (#19: ODT padding without a border, unequal columns, column breaks, picture-only lines); previously trivial (#19: ODT tables' margins and spacing, header spacing, pictures alone in a paragraph); previously trivial (#19: no LibreOffice template changes page count through a save); previously trivial (#19: ODT variables, emphasis marks, page backgrounds, fixed tables, default size); previously trivial (#19: ODT checked against LibreOffice's own templates: placeholders, first-page styles, unsized pages, metafile logos, `.ott`); previously trivial (#19: ODT at ~90%: custom shapes, cell formulas, macros kept, turned text, control sizes and buttons); previously trivial (#19 narrowed: ODT read and written nearly whole; estimate 18–27 h → 10–16 h); previously trivial (#10 narrowed: text in a turned text box is drawn turned with it); previously trivial (gap 19 narrowed: ODT heading numbering read and written); previously trivial (gap 19 narrowed: ODT table borders and padding read and written); previously trivial (gap 19 narrowed: ODT heading style looks read and written); previously trivial (gap 19 narrowed: ODT tab stops read and written); previously trivial (gap 19 narrowed: ODT character formatting read and written); previously trivial (gap 19 narrowed: ODT list formats read and written); previously trivial (gap 19 narrowed: ODT comments read and written); previously trivial (gap 19 narrowed: ODT footnotes and endnotes read and written); previously trivial (gap 19 narrowed: ODT headers and footers written, text fields and paragraph spacing read and written); previously trivial (#8: Options › Language lists Your languages and Add a language… replaces the Language packs table); previously trivial (#8: the missing-pack bar works on a fresh install and counts the caret's language); previously trivial (#8: Language pack languages are in Set Proofing Language, Review › Language and the status bar; built-in proofing is named as such); previously trivial (#20: layout resource caps and linear-time passes (#3867, #3866)); previously trivial (#3 narrowed: a pasted text box story is charged for the formatting it copies); previously trivial (#3 narrowed: a .doc table row keeps one override per cell); previously trivial (#3 narrowed: a .doc file's sections find their paragraphs by index); previously minor (#11: Arabic interface with mirrored shell landed, #1195; hi/id/pt-PT and Hebrew UI remain); previously trivial (#8: language-packs-2 is published and pinned: 75 packs, adding Danish, German (Germany, Austria, Switzerland), Esperanto, Estonian, Persian, Croatian, Hungarian, Norwegian (Bokmål, Nynorsk), Dutch and Swedish (Sweden, Finland); no ranked gap changed); previously trivial (#8: language-packs-1 is published and pinned, 61 packs: Lithuanian, Romanian, Catalan, French, Greek, Slovak, Serbian and Latvian install as Language packs; Dutch, German and the other compounding languages wait on craft-proof; no ranked gap changed); previously minor (#8: Language packs: every other language's spelling and hyphenation installs from File › Options › Language or the missing-pack bar, through the font store; Lithuanian and Romanian are available as a Language pack once language-packs-1 is published; Dutch, Catalan, French, Greek, Slovak, Serbian and Latvian packs wait on craft-proof engine support); previously trivial (gap 8: English spelling reads SCOWL 2026, one dictionary per English, #40, #520, #5205; no ranked gap changed);; previously trivial (DOCX table rows and cells inside selected alternate-content branches survive open and repeated saves (#5219); broader corpus qualification and readiness estimates unchanged); previously trivial (#26 narrowed: MHT opens and `w:altChunk` content is brought in on open; saving MHT remains) previously trivial (gap 8 points at craft-proof in craft-libs, its data in craft-i18n, #5202; no ranked gap changed); previously trivial (arrowheads keep their kind, width and length and are drawn at Word's sizes; no ranked gap changed); previously trivial (.doc default font from the stylesheet's standard font, #5066; no ranked gap changed); previously trivial (a middle or bottom cell of a row split across pages lines up on the first page; no ranked gap changed); previously trivial (tab leader dots spaced and placed as in Word; no ranked gap changed); previously trivial (a list level above counts its first number at the first deeper item; no ranked gap changed); previously trivial (only the PDF sent to the printer leaves out link annotations; Save these pages as PDF keeps them, #4734; no ranked gap changed); previously trivial (documents with links print: the print job leaves out link annotations, #4734; no ranked gap changed; previously trivial: aligned-copy review fixes retain the document axis through scrolling and include secondary selections (#4764)); previously trivial (connector rerouting indexes laid-out object positions once per batch (#3631); previously trivial (custom-property bookmark-link preservation, #4767); previously trivial (Relative font-size commands preserve mixed sizes in the selection (#4903); existing button steps and one-point shortcuts are unchanged; readiness estimates unchanged); previously trivial (Arabic Backspace removes one combining mark and keeps its base letter (#4757); previously trivial (note conversion reference-run membership uses one ordered walk, #4750); previously trivial (DOCX comment-ID save lookups); previously trivial (gap 19: RTF reads and writes WMF and EMF pictures, #4259); previously trivial (#4658 bounds nested Markdown reference-label work); previously trivial (HTML import keeps preformatted lines with CR or CRLF input newlines, #4810); previously trivial (Recipient labels continue across product-sized sheets instead of stopping after the first sheet (#4880)); previously trivial (View windows: several open documents and Switch Windows in the engine; previously trivial: explicit documents keep the editor when recovery discovery finishes; readable recovery controls; previously trivial: text mini toolbar available with the right-click menu, #2959; previously trivial: personal templates in File › New and Save as Word Template, #2852; previously trivial: tracked table/row/cell/section property changes record in WordCraft, narrowing gap 5; previously trivial: a document with many content controls saves in the time the controls take, #13; previously trivial: Format Page Numbers dialog carries Word's number formats and Continue from previous section / Start at, #1113; previously trivial: centred list labels after leading page breaks, #2964; previously trivial: fixed font inputs in four layout controls; previously trivial: a right, centre or decimal tab whose text doesn't fit, or a left tab past the right indent, goes to the next line with its text, #1840; previously trivial: Bullets and Numbering toggle off style-inherited lists at their effective level, including basedOn chains and numbered ListParagraph styles; other paragraphs and list definitions stay unchanged (related to #3459); previously trivial: Russian sorting keeps ё with е and recognises decomposed ё/й; previously trivial: #8: English dialects — en-GB, en-CA, en-AU… flag each other's spellings, #1281; previously trivial: #1: shape gradients and transparency, #1500; previously trivial: text typed into a content control takes the control's formatting; localized placeholder styles recognised; previously trivial: forms protection keeps its content controls: no inserting, Properties or Remove Content Control; previously trivial: clearing a no-match font query keeps the recent heading visible, #2068; previously trivial: line breaking: a slash opening a word travels whole to the next line, #2963; previously trivial: recipient list search and merged-only view, #1576; previously trivial: #2 impact restated: only ink rendering and OLE editing remain; previously trivial: #2 narrowed: native ink nested in groups and drawing canvases kept on save; previously trivial: opening a DOCX no longer copies its pictures; previously trivial: RTF export writes sections (gap 19); previously trivial: ODT export writes sections (gap 19); previously trivial: automatic Asian/Latin and Asian/number spacing laid out, #2358; previously trivial: hint-reliant CJK outlines; previously trivial: numbered headings, #1793; previously trivial: legacy outline, shadow, emboss and imprint text effects drawn, #2534; previously trivial: #8 narrowed: Indonesian proofing from the installed Hunspell dictionary, #498; previously trivial: glossary/building blocks closed; previously trivial: Split Cells and Convert Text to Table follow the Word check, #2592; previously trivial: Language dialog keeps inherited proofing language and no-proof choices (#2717); previously trivial: #29: a copied equation also goes in the MathML clipboard formats, #1297; previously trivial: #24: the Spike, Ctrl+F3 and Ctrl+Shift+F3; previously trivial: VML freeforms read and kept on save; previously trivial: consistent preferred cell widths; previously trivial: multi-paragraph field instructions no longer add blank lines; previously trivial: page-break-only list paragraphs hide their labels; previously trivial: floating-table overlap ignores empty line-break lines; previously trivial: copies keep their formatting on the clipboard as HTML, #1523; previously trivial: sample-text formulas on Enter, #1067; previously trivial: #29: copied equations as MathML, OMML open as #1297, #816; previously trivial: the Font list no longer keeps every previewed font in memory, #848; previously trivial: table column and row markers on the rulers, #700; previously trivial: table borders and the resize handle drag on the page, #217; previously trivial: formatting revisions landed, #41; previously trivial: Draw Table and Eraser landed, #303; previously minor: beta distance restated: ~15 points, ~150–230 h; previously: first version; every known shortfall from the 2026-10-10 re-measure, ranked) · **Target:** Microsoft Word (Microsoft 365) for Mac 16.113.4 > **Page Setup update:** 2026-11-07 · Page Setup number boxes keep long input inside the field, including accepted margin values after focus leaves (#5650); accepted ranges and readiness estimates are unchanged. > **Floating anchor row segments:** 2026-11-07 · A floating anchor after a manual page/column break counts visible content on the far side of the same wrapped row. Marker-only cover anchors retain their previous-page rule. Synthetic picture spacing, placement and history controls; no new native Word measurement. Readiness estimates unchanged. @@ -198,6 +198,9 @@ Page Setup's margin, paper-size and document-grid number boxes scroll long text | Date | Change | Summary | |---|---|---| +| 2026-11-21 | trivial | Pagination gap #4: strict column balancing measures kept paragraphs again after moving them to account for wrap areas in the new column (#6821). Readiness estimates unchanged | +| 2026-11-19 | trivial | Pagination gap #4: strict widow/orphan control releases the wrap area of a float whose anchor moves to another column during balancing (#6821). Readiness estimates unchanged | +| 2026-11-15 | trivial | Balanced columns before a continuous break keep lines together from Word 2013's layout (compatibility mode 15): continued tails, short paragraphs at the top of the last page, kept paragraphs; mode 14 and keep with next on a continued paragraph's last lines still differ from Word (#6821, `layout::tests::balanced_tail`); no ranked gap closed, readiness estimates unchanged | | 2026-11-19 | trivial | #4 narrowed: a narrow Square, Tight or Through logo leaves legacy header lines in place at mode 14. The same lines flow beside the logo at mode 15. Measured in Word for Windows with a synthetic document (#6805). | | 2026-10-31 | trivial | dialogs are dialogs to screen readers, their tabs are tabs, the one shown selected, and colour fields and swatches say their colour | | 2026-11-01 | trivial | formatting shortcuts say what they did to screen readers | diff --git a/docs/layout-parity.md b/docs/layout-parity.md index 3407718f3a..a166cff860 100644 --- a/docs/layout-parity.md +++ b/docs/layout-parity.md @@ -1,6 +1,6 @@ # Layout and pagination parity with Microsoft Word -> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-21 · **Change:** trivial (measured narrow Square, Tight and Through header logos at modes 14 and 15, #6805); previously trivial (headers in compatibility mode 14 and lower keep their text beside their own floating objects, #6805); previously trivial (a row of consecutive hyphens wraps between hyphens, #6856); previously trivial (a paragraph of only a page break moves to the next page when its mark does not fit); previously trivial (table rows split across pages: a cell's first paragraph on the page can split even when only one line fits, if the row starts at the top, with or without its own headers, or continues from the previous page (#6823)); previously trivial (Word 2003's indent rules beside floating objects, `doNotSuppressIndentation`, #5939); previously trivial (a deleted list item's number is drawn as deleted text, #4828); previously minor (added layout.fitOnePage to condense a multi-page document by one page while preserving typography hierarchy); previously trivial (from the second section on, headers, footers and note separators are measured with their own section's document grid and SECTION/SECTIONPAGES values, #4683); previously trivial (a turned inline picture whose file keeps no room for the turn keeps its line to its frame, the frame turned a quarter in Word 2013+ layout); previously trivial (a picture lowered further than its own height lowers its line as far, its top on the baseline); previously trivial (a float anchored right after a page break, before text, is drawn on the new page, #4262); previously trivial (a float anchored on a later page of a long paragraph is drawn there, #4250); previously trivial (the line between columns runs as tall as the section's text, so columns for selected text have it, #5178); previously trivial (a line of only pictures is as tall as they reach, never less than its font's height; a legacy check box sizes its line as text of its size, #3984); previously trivial (spaces before a line's first character keep their width in justified and distributed lines, as in Word); previously trivial (Page drawing indexes text-box warp lookups per paragraph (#3614)); previously trivial (Times and Courier take their Windows counterparts' line spacing; previously trivial: group connector rerouting preserves transformed free and unresolved endpoints under nonuniform scaling; readiness estimates unchanged; previously trivial: a word with no break opportunity in it no longer makes the layout quadratic, #3412; previously trivial: an empty paragraph whose mark is hidden shows nothing, not even its list number, which is still counted, #3982; previously trivial: a Thai run with Latin finds one installed font covering it all on Linux too, #1549; previously trivial: symbol fonts keep their line height without the font; previously trivial: an equation-array row without `&` is centred, #2617; previously trivial: a superscript or subscript sizes its line at the full font size, without its raise or drop, as Word does; previously trivial: an object dragged near the bottom of a page lands where it is dropped, #3169; previously trivial: centred list labels after leading page breaks, #2964; previously trivial: fixed font inputs in four layout controls; previously trivial: justified lines shrink their spaces by Word's measured limits; previously trivial: a right, centre or decimal tab whose text doesn't fit, or a left tab past the right indent, goes to the next line with its text, #1840; previously trivial: a click below a floating table goes to the text beside or after it, not to a cell of its last row, #2038; previously trivial: shapes drawn with their gradients and transparency, #1500; previously trivial: paragraphs above a float's anchor wrap around it, also when that pushes the anchor onto the next page, #2048; previously trivial: triple borders draw three lines, #1740; previously trivial: the caret, clicks and selection edges fall between the letters of a ligature, #1974; previously trivial: a word after a slash wraps whole, like Word, #2963; previously trivial: VML header-cell floats always on the page, user-checked in Word for Mac, #1775; previously trivial: an at-least row with no room for its minimum starts the next page whole, #1742; previously trivial: AutoFit donors lose equal widths down to their content minima; previously trivial: automatic space between Asian text and Latin text or digits, #2358; previously trivial: hint-reliant CJK outlines; previously trivial: positional tabs go to the margins or indents, #2367; previously trivial: field results with right-to-left text read right to left, #1670; previously trivial: a list bullet no installed font can draw shows the level's default bullet, #1683; previously trivial: a missing Thai font is drawn in one Thai face for the whole run, #1549; previously trivial: the caret after spaces hanging past the margin stays at the margin, #2146; previously trivial: covered black-circle fallback before UI sans; previously trivial: resolved split-cell continuation top insets; previously trivial: Symbol PCL6 alias uses Symbol encoding; previously trivial: exact full font names select their installed face; previously trivial: Arial Unicode MS uses proportional fallbacks; previously trivial: DrawingML outline dashes, including zero-width paths; previously trivial: TOCs include table-cell headings and retain full targets; previously trivial: kept table rows follow the next row; previously trivial: consistent cell widths override a stale table grid; previously trivial: multi-paragraph field instructions no longer add blank lines; previously trivial: page-break-only list paragraphs hide their labels; previously trivial: floating-table overlap ignores empty line-break lines; previously trivial: paragraph spacing adds up when the document turns HTML auto spacing off; previously trivial: an inherited footer sizes its percentage tables by its own section; previously trivial: an empty section mark stays on a full page; previously trivial: a fitting row with less room than its minimum height moves on whole; oversized rows still split; previously trivial: text past an exact-height row is cut off; previously trivial: a list number stays with text after a leading page break; previously trivial: a bookmark after a page break takes no line; previously trivial: a page break followed by a page break before or a next-page section starts one page; previously trivial: All Caps and Small Caps draw ß as SS, #1581; previously trivial: justified vertical page alignment, #1320; previously trivial: page numbers restart at 0; previously trivial: a list label moves with its first line when the paragraph is centred or end-aligned (#1159); previously trivial (a click just outside a floating table, by a cell whose text is turned, goes to the text beside or after it, #4181; previously trivial: group connector rerouting preserves transformed free and unresolved endpoints under nonuniform scaling; readiness estimates unchanged; previously trivial: a word with no break opportunity in it no longer makes the layout quadratic, #3412; previously trivial: an empty paragraph whose mark is hidden shows nothing, not even its list number, which is still counted, #3982; previously trivial: a Thai run with Latin finds one installed font covering it all on Linux too, #1549; previously trivial: symbol fonts keep their line height without the font; previously trivial: an equation-array row without `&` is centred, #2617; previously trivial: a superscript or subscript sizes its line at the full font size, without its raise or drop, as Word does; previously trivial: an object dragged near the bottom of a page lands where it is dropped, #3169; previously trivial: centred list labels after leading page breaks, #2964; previously trivial: fixed font inputs in four layout controls; previously trivial: justified lines shrink their spaces by Word's measured limits; previously trivial: a right, centre or decimal tab whose text doesn't fit, or a left tab past the right indent, goes to the next line with its text, #1840; previously trivial: a click below a floating table goes to the text beside or after it, not to a cell of its last row, #2038; previously trivial: shapes drawn with their gradients and transparency, #1500; previously trivial: paragraphs above a float's anchor wrap around it, also when that pushes the anchor onto the next page, #2048; previously trivial: triple borders draw three lines, #1740; previously trivial: the caret, clicks and selection edges fall between the letters of a ligature, #1974; previously trivial: a word after a slash wraps whole, like Word, #2963; previously trivial: VML header-cell floats always on the page, user-checked in Word for Mac, #1775; previously trivial: an at-least row with no room for its minimum starts the next page whole, #1742; previously trivial: AutoFit donors lose equal widths down to their content minima; previously trivial: automatic space between Asian text and Latin text or digits, #2358; previously trivial: hint-reliant CJK outlines; previously trivial: positional tabs go to the margins or indents, #2367; previously trivial: field results with right-to-left text read right to left, #1670; previously trivial: a list bullet no installed font can draw shows the level's default bullet, #1683; previously trivial: a missing Thai font is drawn in one Thai face for the whole run, #1549; previously trivial: the caret after spaces hanging past the margin stays at the margin, #2146; previously trivial: covered black-circle fallback before UI sans; previously trivial: resolved split-cell continuation top insets; previously trivial: Symbol PCL6 alias uses Symbol encoding; previously trivial: exact full font names select their installed face; previously trivial: Arial Unicode MS uses proportional fallbacks; previously trivial: DrawingML outline dashes, including zero-width paths; previously trivial: TOCs include table-cell headings and retain full targets; previously trivial: kept table rows follow the next row; previously trivial: consistent cell widths override a stale table grid; previously trivial: multi-paragraph field instructions no longer add blank lines; previously trivial: page-break-only list paragraphs hide their labels; previously trivial: floating-table overlap ignores empty line-break lines; previously trivial: paragraph spacing adds up when the document turns HTML auto spacing off; previously trivial: an inherited footer sizes its percentage tables by its own section; previously trivial: an empty section mark stays on a full page; previously trivial: a fitting row with less room than its minimum height moves on whole; oversized rows still split; previously trivial: text past an exact-height row is cut off; previously trivial: a list number stays with text after a leading page break; previously trivial: a bookmark after a page break takes no line; previously trivial: a page break followed by a page break before or a next-page section starts one page; previously trivial: All Caps and Small Caps draw ß as SS, #1581; previously trivial: justified vertical page alignment, #1320; previously trivial: page numbers restart at 0; previously trivial: a list label moves with its first line when the paragraph is centred or end-aligned (#1159); previously trivial (PR #4545: eligible cell floats keep in-bounds offsets; overflow confinement retains the front-of-text, turned-cell and native-acceptance limits); previously trivial (MATH construction reuse, #3630; previously trivial: continuous sections one after another go onto new pages instead of running off the page; empty marks after another empty section mark take a line each until the page is full, then stay at its bottom drawing nothing, not even a list label; an empty mark that takes no room draws no list label either; a kept-together paragraph is measured against the page it would move to, so a tall different first-page header no longer splits it, #3907; previously trivial: a justified line ending in a manual line break is stretched to the margin unless `w:doNotExpandShiftReturn` is set, #3924; previously trivial: a no-break space is as wide as a space, #4192; previously trivial: a bookmark or other zero-width marker is no line-break opportunity, #4193; previously trivial: Arabic list labels: `arabicAlpha` and `arabicAbjad` draw the 28 Arabic letters (alphabetical and abjad order), doubling past the last letter; Hebrew, Hindi, Thai and Vietnamese still show decimal (`doc::section::tests::arabic_letters_count_in_both_orders`); previously trivial (ODT documents: a line of only pictures keeps its font's height; no setting for it any more); previously trivial (ODT documents: padding is the standard's box model always; picture-only line height is an ODF interpretation setting); previously trivial (行頭禁則 also covers the small kana and the prolonged sound mark at ordinary break opportunities, as JIS X 4051 §4 specifies, inferred from the standard and synthetic tests rather than checked in Word); previously trivial (a missing font is drawn in an installed metric twin before any other substitute: Arial for Helvetica on Windows, Tinos before macOS Times for Times New Roman); previously trivial (ODT documents: padding without a border takes room); previously trivial (ODT documents: a line of only pictures is as tall as they are); previously trivial (ODT documents: a table's own space above and below; header and footer spacing kept past a tall header); previously trivial (a page break before a table's first row moves the table; emphasis marks drawn with room in the line); previously trivial (text in a turned text box turns with it; previously trivial: an in-line picture, shape or chart moves with its run's raise or lowering, Word's `w:position`; previously trivial (layout work bounds: header-row repeats budgeted per layout, cached picture outlines charged to the decode budget, linked-box chain widths exact up to a work cap, #3867); previously trivial (the line between columns runs as tall as the section's text, so columns for selected text have it, #5178); previously trivial (a table row that would leave a cell empty on a page that already holds something, its picture or first line not fitting there, moves on whole instead of leaving the other cells' text beside the empty cell, #4272); previously trivial (a middle or bottom cell of a row split across pages lines up on the first page); previously trivial (tab leader dots spaced and placed as in Word); previously trivial (a level above that hasn't counted yet takes its first number at the first deeper item); previously trivial (paragraph side borders lie beyond their distance from the text, #5036); previously trivial (with a header taller than the top margin, Margin-anchored drawings, header-cell pins and header-table obstacles use the rendered body top; TopMargin and InsideMargin keep their declared band, #2485; previously trivial: connector rerouting indexes laid-out object positions once per batch (#3631); previously trivial (field results take the `\* DollarText`, `\* Hex` and `\* ArabicDash` switches, #4226; previously trivial: a cell spanning columns shares its extra minimum width by the columns' preferred widths, equally in automatic tables, #1883; previously trivial: continuous sections one after another go onto new pages instead of running off the page; empty marks after another empty section mark take a line each until the page is full, then stay at its bottom drawing nothing, not even a list label; an empty mark that takes no room draws no list label either; a kept-together paragraph is measured against the page it would move to, so a tall different first-page header no longer splits it, #3907; previously trivial: a justified line ending in a manual line break is stretched to the margin unless `w:doNotExpandShiftReturn` is set, #3924; previously trivial: a no-break space is as wide as a space, #4192; previously trivial: a bookmark or other zero-width marker is no line-break opportunity, #4193; previously trivial: Arabic list labels: `arabicAlpha` and `arabicAbjad` draw the 28 Arabic letters (alphabetical and abjad order), doubling past the last letter; Hebrew, Hindi, Thai and Vietnamese still show decimal (`doc::section::tests::arabic_letters_count_in_both_orders`); previously trivial: Preserve grapheme edit/wrap boundaries across independently drawn font/style pieces; Exact-spacing table contact uses the specified line height rather than paragraph-mark metrics (#3977); previously trivial: cu20we: restrict pre-spacing float origins to paragraph anchors; document cap helpers and regressions; previously trivial: cu20we: outline caps; previously trivial: cu20we: box float paragraph origin; previously trivial: group connector rerouting preserves transformed free and unresolved endpoints under nonuniform scaling; readiness estimates unchanged; previously trivial: a word with no break opportunity in it no longer makes the layout quadratic, #3412; previously trivial: an empty paragraph whose mark is hidden shows nothing, not even its list number, which is still counted, #3982; previously trivial: a Thai run with Latin finds one installed font covering it all on Linux too, #1549; previously trivial: symbol fonts keep their line height without the font; previously trivial: an equation-array row without `&` is centred, #2617; previously trivial: a superscript or subscript sizes its line at the full font size, without its raise or drop, as Word does; previously trivial: an object dragged near the bottom of a page lands where it is dropped, #3169; previously trivial: centred list labels after leading page breaks, #2964; previously trivial: fixed font inputs in four layout controls; previously trivial: justified lines shrink their spaces by Word's measured limits; previously trivial: a right, centre or decimal tab whose text doesn't fit, or a left tab past the right indent, goes to the next line with its text, #1840; previously trivial: a click below a floating table goes to the text beside or after it, not to a cell of its last row, #2038; previously trivial: shapes drawn with their gradients and transparency, #1500; previously trivial: paragraphs above a float's anchor wrap around it, also when that pushes the anchor onto the next page, #2048; previously trivial: triple borders draw three lines, #1740; previously trivial: the caret, clicks and selection edges fall between the letters of a ligature, #1974; previously trivial: a word after a slash wraps whole, like Word, #2963; previously trivial: VML header-cell floats always on the page, user-checked in Word for Mac, #1775; previously trivial: an at-least row with no room for its minimum starts the next page whole, #1742; previously trivial: AutoFit donors lose equal widths down to their content minima; previously trivial: automatic space between Asian text and Latin text or digits, #2358; previously trivial: hint-reliant CJK outlines; previously trivial: positional tabs go to the margins or indents, #2367; previously trivial: field results with right-to-left text read right to left, #1670; previously trivial: a list bullet no installed font can draw shows the level's default bullet, #1683; previously trivial: a missing Thai font is drawn in one Thai face for the whole run, #1549; previously trivial: the caret after spaces hanging past the margin stays at the margin, #2146; previously trivial: covered black-circle fallback before UI sans; previously trivial: resolved split-cell continuation top insets; previously trivial: Symbol PCL6 alias uses Symbol encoding; previously trivial: exact full font names select their installed face; previously trivial: Arial Unicode MS uses proportional fallbacks; previously trivial: DrawingML outline dashes, including zero-width paths; previously trivial: TOCs include table-cell headings and retain full targets; previously trivial: kept table rows follow the next row; previously trivial: consistent cell widths override a stale table grid; previously trivial: multi-paragraph field instructions no longer add blank lines; previously trivial: page-break-only list paragraphs hide their labels; previously trivial: floating-table overlap ignores empty line-break lines; previously trivial: paragraph spacing adds up when the document turns HTML auto spacing off; previously trivial: an inherited footer sizes its percentage tables by its own section; previously trivial: an empty section mark stays on a full page; previously trivial: a fitting row with less room than its minimum height moves on whole; oversized rows still split; previously trivial: text past an exact-height row is cut off; previously trivial: a list number stays with text after a leading page break; previously trivial: a bookmark after a page break takes no line; previously trivial: a page break followed by a page break before or a next-page section starts one page; previously trivial: All Caps and Small Caps draw ß as SS, #1581; previously trivial: justified vertical page alignment, #1320; previously trivial: page numbers restart at 0; previously trivial: a list label moves with its first line when the paragraph is centred or end-aligned (#1159); previously trivial: PAGE fields in a paragraph split across pages show the page they are on, #1352; previously trivial: a dragged floating object anchors in the column it lands in, #884; previously trivial: a paragraph ending on a page with footnotes keeps its space after above the separator, #1116; previously trivial: symbol-font text drawn as Unicode symbols, #776; previously trivial: large-table scrolling measured and fixed, #811; previously trivial: text boxes use their own margins; Resize shape to fit text never cuts text, #743; previously trivial: complex-script shaping and Myanmar line breaking, #604; previously trivial: body page totals, table-cell footnotes and bookmark link pages fixed, #450 #451 #455; previously major: first version; line breaking, pagination and object placement checked against Word's behaviour from the layout source on origin/main) · **Target:** Microsoft Word (Microsoft 365) for Mac 16.113.4 +> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-11-21 · **Change:** trivial (release wrap areas when strict column balancing moves the anchor line, #6821); previously trivial (balanced columns keep lines together from Word 2013's layout: tails, whole short paragraphs, kept paragraphs, beside notes and floats, #6821); previously trivial (measured narrow Square, Tight and Through header logos at modes 14 and 15, #6805); previously trivial (headers in compatibility mode 14 and lower keep their text beside their own floating objects, #6805); previously trivial (a row of consecutive hyphens wraps between hyphens, #6856); previously trivial (a paragraph of only a page break moves to the next page when its mark does not fit); previously trivial (table rows split across pages: a cell's first paragraph on the page can split even when only one line fits, if the row starts at the top, with or without its own headers, or continues from the previous page (#6823)); previously trivial (Word 2003's indent rules beside floating objects, `doNotSuppressIndentation`, #5939); previously trivial (a deleted list item's number is drawn as deleted text, #4828); previously minor (added layout.fitOnePage to condense a multi-page document by one page while preserving typography hierarchy); previously trivial (from the second section on, headers, footers and note separators are measured with their own section's document grid and SECTION/SECTIONPAGES values, #4683); previously trivial (a turned inline picture whose file keeps no room for the turn keeps its line to its frame, the frame turned a quarter in Word 2013+ layout); previously trivial (a picture lowered further than its own height lowers its line as far, its top on the baseline); previously trivial (a float anchored right after a page break, before text, is drawn on the new page, #4262); previously trivial (a float anchored on a later page of a long paragraph is drawn there, #4250); previously trivial (the line between columns runs as tall as the section's text, so columns for selected text have it, #5178); previously trivial (a line of only pictures is as tall as they reach, never less than its font's height; a legacy check box sizes its line as text of its size, #3984); previously trivial (spaces before a line's first character keep their width in justified and distributed lines, as in Word); previously trivial (Page drawing indexes text-box warp lookups per paragraph (#3614)); previously trivial (Times and Courier take their Windows counterparts' line spacing; previously trivial: group connector rerouting preserves transformed free and unresolved endpoints under nonuniform scaling; readiness estimates unchanged; previously trivial: a word with no break opportunity in it no longer makes the layout quadratic, #3412; previously trivial: an empty paragraph whose mark is hidden shows nothing, not even its list number, which is still counted, #3982; previously trivial: a Thai run with Latin finds one installed font covering it all on Linux too, #1549; previously trivial: symbol fonts keep their line height without the font; previously trivial: an equation-array row without `&` is centred, #2617; previously trivial: a superscript or subscript sizes its line at the full font size, without its raise or drop, as Word does; previously trivial: an object dragged near the bottom of a page lands where it is dropped, #3169; previously trivial: centred list labels after leading page breaks, #2964; previously trivial: fixed font inputs in four layout controls; previously trivial: justified lines shrink their spaces by Word's measured limits; previously trivial: a right, centre or decimal tab whose text doesn't fit, or a left tab past the right indent, goes to the next line with its text, #1840; previously trivial: a click below a floating table goes to the text beside or after it, not to a cell of its last row, #2038; previously trivial: shapes drawn with their gradients and transparency, #1500; previously trivial: paragraphs above a float's anchor wrap around it, also when that pushes the anchor onto the next page, #2048; previously trivial: triple borders draw three lines, #1740; previously trivial: the caret, clicks and selection edges fall between the letters of a ligature, #1974; previously trivial: a word after a slash wraps whole, like Word, #2963; previously trivial: VML header-cell floats always on the page, user-checked in Word for Mac, #1775; previously trivial: an at-least row with no room for its minimum starts the next page whole, #1742; previously trivial: AutoFit donors lose equal widths down to their content minima; previously trivial: automatic space between Asian text and Latin text or digits, #2358; previously trivial: hint-reliant CJK outlines; previously trivial: positional tabs go to the margins or indents, #2367; previously trivial: field results with right-to-left text read right to left, #1670; previously trivial: a list bullet no installed font can draw shows the level's default bullet, #1683; previously trivial: a missing Thai font is drawn in one Thai face for the whole run, #1549; previously trivial: the caret after spaces hanging past the margin stays at the margin, #2146; previously trivial: covered black-circle fallback before UI sans; previously trivial: resolved split-cell continuation top insets; previously trivial: Symbol PCL6 alias uses Symbol encoding; previously trivial: exact full font names select their installed face; previously trivial: Arial Unicode MS uses proportional fallbacks; previously trivial: DrawingML outline dashes, including zero-width paths; previously trivial: TOCs include table-cell headings and retain full targets; previously trivial: kept table rows follow the next row; previously trivial: consistent cell widths override a stale table grid; previously trivial: multi-paragraph field instructions no longer add blank lines; previously trivial: page-break-only list paragraphs hide their labels; previously trivial: floating-table overlap ignores empty line-break lines; previously trivial: paragraph spacing adds up when the document turns HTML auto spacing off; previously trivial: an inherited footer sizes its percentage tables by its own section; previously trivial: an empty section mark stays on a full page; previously trivial: a fitting row with less room than its minimum height moves on whole; oversized rows still split; previously trivial: text past an exact-height row is cut off; previously trivial: a list number stays with text after a leading page break; previously trivial: a bookmark after a page break takes no line; previously trivial: a page break followed by a page break before or a next-page section starts one page; previously trivial: All Caps and Small Caps draw ß as SS, #1581; previously trivial: justified vertical page alignment, #1320; previously trivial: page numbers restart at 0; previously trivial: a list label moves with its first line when the paragraph is centred or end-aligned (#1159); previously trivial (a click just outside a floating table, by a cell whose text is turned, goes to the text beside or after it, #4181; previously trivial: group connector rerouting preserves transformed free and unresolved endpoints under nonuniform scaling; readiness estimates unchanged; previously trivial: a word with no break opportunity in it no longer makes the layout quadratic, #3412; previously trivial: an empty paragraph whose mark is hidden shows nothing, not even its list number, which is still counted, #3982; previously trivial: a Thai run with Latin finds one installed font covering it all on Linux too, #1549; previously trivial: symbol fonts keep their line height without the font; previously trivial: an equation-array row without `&` is centred, #2617; previously trivial: a superscript or subscript sizes its line at the full font size, without its raise or drop, as Word does; previously trivial: an object dragged near the bottom of a page lands where it is dropped, #3169; previously trivial: centred list labels after leading page breaks, #2964; previously trivial: fixed font inputs in four layout controls; previously trivial: justified lines shrink their spaces by Word's measured limits; previously trivial: a right, centre or decimal tab whose text doesn't fit, or a left tab past the right indent, goes to the next line with its text, #1840; previously trivial: a click below a floating table goes to the text beside or after it, not to a cell of its last row, #2038; previously trivial: shapes drawn with their gradients and transparency, #1500; previously trivial: paragraphs above a float's anchor wrap around it, also when that pushes the anchor onto the next page, #2048; previously trivial: triple borders draw three lines, #1740; previously trivial: the caret, clicks and selection edges fall between the letters of a ligature, #1974; previously trivial: a word after a slash wraps whole, like Word, #2963; previously trivial: VML header-cell floats always on the page, user-checked in Word for Mac, #1775; previously trivial: an at-least row with no room for its minimum starts the next page whole, #1742; previously trivial: AutoFit donors lose equal widths down to their content minima; previously trivial: automatic space between Asian text and Latin text or digits, #2358; previously trivial: hint-reliant CJK outlines; previously trivial: positional tabs go to the margins or indents, #2367; previously trivial: field results with right-to-left text read right to left, #1670; previously trivial: a list bullet no installed font can draw shows the level's default bullet, #1683; previously trivial: a missing Thai font is drawn in one Thai face for the whole run, #1549; previously trivial: the caret after spaces hanging past the margin stays at the margin, #2146; previously trivial: covered black-circle fallback before UI sans; previously trivial: resolved split-cell continuation top insets; previously trivial: Symbol PCL6 alias uses Symbol encoding; previously trivial: exact full font names select their installed face; previously trivial: Arial Unicode MS uses proportional fallbacks; previously trivial: DrawingML outline dashes, including zero-width paths; previously trivial: TOCs include table-cell headings and retain full targets; previously trivial: kept table rows follow the next row; previously trivial: consistent cell widths override a stale table grid; previously trivial: multi-paragraph field instructions no longer add blank lines; previously trivial: page-break-only list paragraphs hide their labels; previously trivial: floating-table overlap ignores empty line-break lines; previously trivial: paragraph spacing adds up when the document turns HTML auto spacing off; previously trivial: an inherited footer sizes its percentage tables by its own section; previously trivial: an empty section mark stays on a full page; previously trivial: a fitting row with less room than its minimum height moves on whole; oversized rows still split; previously trivial: text past an exact-height row is cut off; previously trivial: a list number stays with text after a leading page break; previously trivial: a bookmark after a page break takes no line; previously trivial: a page break followed by a page break before or a next-page section starts one page; previously trivial: All Caps and Small Caps draw ß as SS, #1581; previously trivial: justified vertical page alignment, #1320; previously trivial: page numbers restart at 0; previously trivial: a list label moves with its first line when the paragraph is centred or end-aligned (#1159); previously trivial (PR #4545: eligible cell floats keep in-bounds offsets; overflow confinement retains the front-of-text, turned-cell and native-acceptance limits); previously trivial (MATH construction reuse, #3630; previously trivial: continuous sections one after another go onto new pages instead of running off the page; empty marks after another empty section mark take a line each until the page is full, then stay at its bottom drawing nothing, not even a list label; an empty mark that takes no room draws no list label either; a kept-together paragraph is measured against the page it would move to, so a tall different first-page header no longer splits it, #3907; previously trivial: a justified line ending in a manual line break is stretched to the margin unless `w:doNotExpandShiftReturn` is set, #3924; previously trivial: a no-break space is as wide as a space, #4192; previously trivial: a bookmark or other zero-width marker is no line-break opportunity, #4193; previously trivial: Arabic list labels: `arabicAlpha` and `arabicAbjad` draw the 28 Arabic letters (alphabetical and abjad order), doubling past the last letter; Hebrew, Hindi, Thai and Vietnamese still show decimal (`doc::section::tests::arabic_letters_count_in_both_orders`); previously trivial (ODT documents: a line of only pictures keeps its font's height; no setting for it any more); previously trivial (ODT documents: padding is the standard's box model always; picture-only line height is an ODF interpretation setting); previously trivial (行頭禁則 also covers the small kana and the prolonged sound mark at ordinary break opportunities, as JIS X 4051 §4 specifies, inferred from the standard and synthetic tests rather than checked in Word); previously trivial (a missing font is drawn in an installed metric twin before any other substitute: Arial for Helvetica on Windows, Tinos before macOS Times for Times New Roman); previously trivial (ODT documents: padding without a border takes room); previously trivial (ODT documents: a line of only pictures is as tall as they are); previously trivial (ODT documents: a table's own space above and below; header and footer spacing kept past a tall header); previously trivial (a page break before a table's first row moves the table; emphasis marks drawn with room in the line); previously trivial (text in a turned text box turns with it; previously trivial: an in-line picture, shape or chart moves with its run's raise or lowering, Word's `w:position`; previously trivial (layout work bounds: header-row repeats budgeted per layout, cached picture outlines charged to the decode budget, linked-box chain widths exact up to a work cap, #3867); previously trivial (the line between columns runs as tall as the section's text, so columns for selected text have it, #5178); previously trivial (a table row that would leave a cell empty on a page that already holds something, its picture or first line not fitting there, moves on whole instead of leaving the other cells' text beside the empty cell, #4272); previously trivial (a middle or bottom cell of a row split across pages lines up on the first page); previously trivial (tab leader dots spaced and placed as in Word); previously trivial (a level above that hasn't counted yet takes its first number at the first deeper item); previously trivial (paragraph side borders lie beyond their distance from the text, #5036); previously trivial (with a header taller than the top margin, Margin-anchored drawings, header-cell pins and header-table obstacles use the rendered body top; TopMargin and InsideMargin keep their declared band, #2485; previously trivial: connector rerouting indexes laid-out object positions once per batch (#3631); previously trivial (field results take the `\* DollarText`, `\* Hex` and `\* ArabicDash` switches, #4226; previously trivial: a cell spanning columns shares its extra minimum width by the columns' preferred widths, equally in automatic tables, #1883; previously trivial: continuous sections one after another go onto new pages instead of running off the page; empty marks after another empty section mark take a line each until the page is full, then stay at its bottom drawing nothing, not even a list label; an empty mark that takes no room draws no list label either; a kept-together paragraph is measured against the page it would move to, so a tall different first-page header no longer splits it, #3907; previously trivial: a justified line ending in a manual line break is stretched to the margin unless `w:doNotExpandShiftReturn` is set, #3924; previously trivial: a no-break space is as wide as a space, #4192; previously trivial: a bookmark or other zero-width marker is no line-break opportunity, #4193; previously trivial: Arabic list labels: `arabicAlpha` and `arabicAbjad` draw the 28 Arabic letters (alphabetical and abjad order), doubling past the last letter; Hebrew, Hindi, Thai and Vietnamese still show decimal (`doc::section::tests::arabic_letters_count_in_both_orders`); previously trivial: Preserve grapheme edit/wrap boundaries across independently drawn font/style pieces; Exact-spacing table contact uses the specified line height rather than paragraph-mark metrics (#3977); previously trivial: cu20we: restrict pre-spacing float origins to paragraph anchors; document cap helpers and regressions; previously trivial: cu20we: outline caps; previously trivial: cu20we: box float paragraph origin; previously trivial: group connector rerouting preserves transformed free and unresolved endpoints under nonuniform scaling; readiness estimates unchanged; previously trivial: a word with no break opportunity in it no longer makes the layout quadratic, #3412; previously trivial: an empty paragraph whose mark is hidden shows nothing, not even its list number, which is still counted, #3982; previously trivial: a Thai run with Latin finds one installed font covering it all on Linux too, #1549; previously trivial: symbol fonts keep their line height without the font; previously trivial: an equation-array row without `&` is centred, #2617; previously trivial: a superscript or subscript sizes its line at the full font size, without its raise or drop, as Word does; previously trivial: an object dragged near the bottom of a page lands where it is dropped, #3169; previously trivial: centred list labels after leading page breaks, #2964; previously trivial: fixed font inputs in four layout controls; previously trivial: justified lines shrink their spaces by Word's measured limits; previously trivial: a right, centre or decimal tab whose text doesn't fit, or a left tab past the right indent, goes to the next line with its text, #1840; previously trivial: a click below a floating table goes to the text beside or after it, not to a cell of its last row, #2038; previously trivial: shapes drawn with their gradients and transparency, #1500; previously trivial: paragraphs above a float's anchor wrap around it, also when that pushes the anchor onto the next page, #2048; previously trivial: triple borders draw three lines, #1740; previously trivial: the caret, clicks and selection edges fall between the letters of a ligature, #1974; previously trivial: a word after a slash wraps whole, like Word, #2963; previously trivial: VML header-cell floats always on the page, user-checked in Word for Mac, #1775; previously trivial: an at-least row with no room for its minimum starts the next page whole, #1742; previously trivial: AutoFit donors lose equal widths down to their content minima; previously trivial: automatic space between Asian text and Latin text or digits, #2358; previously trivial: hint-reliant CJK outlines; previously trivial: positional tabs go to the margins or indents, #2367; previously trivial: field results with right-to-left text read right to left, #1670; previously trivial: a list bullet no installed font can draw shows the level's default bullet, #1683; previously trivial: a missing Thai font is drawn in one Thai face for the whole run, #1549; previously trivial: the caret after spaces hanging past the margin stays at the margin, #2146; previously trivial: covered black-circle fallback before UI sans; previously trivial: resolved split-cell continuation top insets; previously trivial: Symbol PCL6 alias uses Symbol encoding; previously trivial: exact full font names select their installed face; previously trivial: Arial Unicode MS uses proportional fallbacks; previously trivial: DrawingML outline dashes, including zero-width paths; previously trivial: TOCs include table-cell headings and retain full targets; previously trivial: kept table rows follow the next row; previously trivial: consistent cell widths override a stale table grid; previously trivial: multi-paragraph field instructions no longer add blank lines; previously trivial: page-break-only list paragraphs hide their labels; previously trivial: floating-table overlap ignores empty line-break lines; previously trivial: paragraph spacing adds up when the document turns HTML auto spacing off; previously trivial: an inherited footer sizes its percentage tables by its own section; previously trivial: an empty section mark stays on a full page; previously trivial: a fitting row with less room than its minimum height moves on whole; oversized rows still split; previously trivial: text past an exact-height row is cut off; previously trivial: a list number stays with text after a leading page break; previously trivial: a bookmark after a page break takes no line; previously trivial: a page break followed by a page break before or a next-page section starts one page; previously trivial: All Caps and Small Caps draw ß as SS, #1581; previously trivial: justified vertical page alignment, #1320; previously trivial: page numbers restart at 0; previously trivial: a list label moves with its first line when the paragraph is centred or end-aligned (#1159); previously trivial: PAGE fields in a paragraph split across pages show the page they are on, #1352; previously trivial: a dragged floating object anchors in the column it lands in, #884; previously trivial: a paragraph ending on a page with footnotes keeps its space after above the separator, #1116; previously trivial: symbol-font text drawn as Unicode symbols, #776; previously trivial: large-table scrolling measured and fixed, #811; previously trivial: text boxes use their own margins; Resize shape to fit text never cuts text, #743; previously trivial: complex-script shaping and Myanmar line breaking, #604; previously trivial: body page totals, table-cell footnotes and bookmark link pages fixed, #450 #451 #455; previously major: first version; line breaking, pagination and object placement checked against Word's behaviour from the layout source on origin/main) · **Target:** Microsoft Word (Microsoft 365) for Mac 16.113.4 > **Floating anchor row segments:** 2026-11-07 · A floating anchor after a manual page/column break counts visible content on the far side of the same wrapped row. Marker-only cover anchors retain their previous-page rule. Synthetic picture spacing, placement and history controls; no new native Word measurement. Readiness estimates unchanged. > **Legacy header floats:** 2026-11-19 · In compatibility mode 14 and lower a header's text keeps its position around the header's own Square and Top and Bottom objects. A Top and Bottom object makes the header taller when it starts above the text's end. The header also keeps its position around Tight and Through objects in mode 14, the legacy mode measured for those wraps. From mode 15 the text flows below a Top and Bottom object or beside a narrow logo. Measured in Word for Windows 16.0 on synthetic files (Top and Bottom in modes 11, 12, 14 and 15, and Square, Tight and Through in modes 14 and 15). Body text wrapping around header objects, footers and header table cells remain outside this change (#6805). @@ -288,6 +288,12 @@ The front-of-text opt-out is retained from the earlier implementation; this patc ## Revision history +> 2026-11-21 · When strict column balancing moves a kept paragraph between columns, it measures the paragraph again in each candidate column. A floating object that narrows one column no longer causes the paragraph to skip a later column where it fits (#6821). + +> 2026-11-19 · Balanced columns before a continuous break (#6821). From compatibility mode 15, strict widow/orphan control applies at the top of a column and avoids leaving a single line of a paragraph there when it continues into the next column. The strict rules also keep a paragraph together when requested, including with the next paragraph. When the strict rules cannot fit within the full column height, balancing retries with relaxed rules. The measured Word comparisons used synthetic documents with exact 14 pt lines, two and three columns, and modes 14 and 15. `layout::tests::balanced_tail` also covers tails beside a footnote or a square-wrapped picture with synthetic tests. Plain page flow with widow control on and off, with and without a footnote, was measured in Word and already matched. It has no new test here. Mode 14 still splits a two-line tail one per column. Its three-line tail, two-line paragraph after one line, and section-end spacing with automatic line spacing still differ, as does keep with next on the last lines of a paragraph that started on the preceding page. + +> 2026-11-19 · A continued paragraph that strict widow/orphan control moves out of a fresh column takes its floating object's wrap area with it. A line that overflows the column keeps its float because the line is still drawn there (#6821). + > 2026-11-15 · Headers at compatibility mode 14 and lower: the header's text keeps its place beside its own floating objects; a top and bottom object starting above the text's end makes the header taller (#6805). > 2026-11-19 · A 60 pt header logo with Square, Tight or Through wrapping leaves three short header lines at the left margin in mode 14. In mode 15 they flow beside the logo. Verified in Word for Windows with a synthetic document (#6805).