Honour TeX looseness when an alternative line count exists
This commit is contained in:
1 parent
96cd98f833
commit
a6397fcfef
6 files changed
+219
-99
No files matched your search
+2
-4
@@ -140,9 +140,7 @@ and justification.
|
||||
a zero code leaves the running factor unchanged, as in TeX. Explicit
|
||||
`\spaceskip`/`\xspaceskip` replace the font glue, and hyphenation applies
|
||||
to a word's letter core so trailing punctuation does not suppress the
|
||||
pattern lookup (pdfTeX breaks `epsilon:` as `ep-`). `ParagraphStyle::ragged_right` models `\raggedright`: lines keep their natural width and fill greedily, because the infinite `fil` in `\rightskip` leaves no reason to stretch. `\looseness` shifts the paragraph by whole lines when
|
||||
the requested count lies between one and nine lines away from the natural
|
||||
count (the adjustment is reverted when no feasible layout exists).
|
||||
pattern lookup (pdfTeX breaks `epsilon:` as `ep-`). `ParagraphStyle::ragged_right` models `\raggedright`: lines keep their natural width and fill greedily, because the infinite `fil` in `\rightskip` leaves no reason to stretch. `\looseness` asks for the natural line count shifted by up to nine lines (TeX's `[1,9]` window); the shift is kept only while a feasible layout exists at that count. When the requested count is infeasible pdfLaTeX can still emit a different alternative optimum; route-D keeps the ordinary optimum there, which the unit tests pin.
|
||||
Interline glue follows TeX: each baseline advances by `\baselineskip` when
|
||||
the resulting gap clears `\lineskiplimit`, otherwise by `\lineskip`;
|
||||
`\parskip` is appended between paragraph units in the vertical list. When a
|
||||
@@ -346,7 +344,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 288 unit tests plus seven route-D integration tests and twenty-four oracle fixtures. Workspace verification: `cargo fmt --all -- --check`; `cargo test --workspace --offline` runs 424 tests (288 route-D unit, 7 route-D integration, 24 oracle, 71 v1 integration, 26 server, 4 v1 unit, 1 core unit, 3 binary units), with none ignored. v1 remains the live server path.
|
||||
The crate currently has 289 unit tests plus seven route-D integration tests and twenty-five oracle fixtures. Workspace verification: `cargo fmt --all -- --check`; `cargo test --workspace --offline` runs 426 tests (289 route-D unit, 7 route-D integration, 25 oracle, 71 v1 integration, 26 server, 4 v1 unit, 1 core unit, 3 binary units), with none ignored. v1 remains the live server path.
|
||||
|
||||
### M0 incremental demo
|
||||
|
||||
|
||||
Reference in new issue
Block a user