Reject overfull lines outside the emergency pass

This commit is contained in:
gloamxun committed 2026-10-23 03:17:25 +08:00
1 parent 47ef33c536
commit c8805af755
3 files changed
+34 -6

No files matched your search

+6 -5
View File
@@ -48,7 +48,7 @@ floats (`\floatsep`, `\textfloatsep`, `\intextsep`, `\topfraction`,
`\bottomnumber`, `\totalnumber`), insertion classes (`\skip`, fraction and
absolute limits, splitting), marks, Rust output hook, multi-page PDF, and the
route-D service endpoints (`/api/route-d/preview|pdf|edit`, project preview and
PDF opt-in with `?engine=route-d`). 352 workspace tests are green and no oracle
PDF opt-in with `?engine=route-d`). 353 workspace tests are green and no oracle
fixture is ignored.
Known gaps, in dependency order:
@@ -224,10 +224,11 @@ top of a page (see `Paragraph::split_at`).
Still open: generic `fil`/`fill` glue orders, `\prevgraf`, explicit
`\vskip` classes (`\smallskip` and friends),
double/final hyphen demerit oracle fixtures. Default-register probes show no
sensitivity to `\finalhyphendemerits`; forcing `\tolerance=10000` makes
pdfLaTeX hyphenate where our DP keeps one overfull line, so the demerit
fixtures need that divergence explained first.
double/final hyphen demerit oracle fixtures. The breaker now rejects overfull
lines outside the emergency pass, exactly like TeX, so `\tolerance` cannot
smuggle in a single overfull line any more; at `\tolerance=10000` the line
count matches pdfLaTeX but the first line boundary still differs, so the
demerit fixtures stay open until that trade-off is understood.
### P2 — Vertical list, page builder, `\output` (L2)
+1 -1
View File
@@ -332,7 +332,7 @@ Math coverage includes fractions/roots, scripts, `\left...\right` with body-scal
Paragraph units carry a `ParagraphFont`; `Unit::paragraph_with_face` and `Unit::paragraph_with_style_and_face` select Roman, bold, italic, mono, or sans. The corresponding Computer Modern TFM (`cmr10`, `cmbx10`, `cmti10`, `cmbxti10`, `cmtt10`, `cmss10`) supplies advances, kerns, ligatures, and italic correction for layout, while the display list and PDF select the matching Liberation face. `Engine::edit` preserves the face when reflowing an edited paragraph.
The crate currently has 234 unit tests plus seven route-D integration tests and thirteen oracle fixtures. Workspace verification: `cargo fmt --all -- --check`; `cargo test --workspace --offline` runs 352 tests (234 route-D unit, 7 route-D integration, 13 oracle, 71 v1 integration, 20 server, 4 v1 unit, 1 core unit, 2 binary units), with none ignored. v1 remains the live server path.
The crate currently has 235 unit tests plus seven route-D integration tests and thirteen oracle fixtures. Workspace verification: `cargo fmt --all -- --check`; `cargo test --workspace --offline` runs 353 tests (235 route-D unit, 7 route-D integration, 13 oracle, 71 v1 integration, 20 server, 4 v1 unit, 1 core unit, 2 binary units), with none ignored. v1 remains the live server path.
### M0 incremental demo