Repository navigation
Conversation
…amsmath's definition when amsmath is loaded
`math::parse_tokens` took no package context, so every construct a
package redefines silently got the LaTeX kernel's definition -- the
wrong one whenever the document actually loaded the package. `\colon`
is the case that forced this: the kernel declares it punctuation
(`fontmath.ltx` 400, `\DeclareMathSymbol{\colon}{\mathpunct}{operators}
{"3A}`, 0mu/3mu) and amsmath renews it (`amsmath.sty` 409-410) to
`\nobreak\mskip2mu\mathpunct{}\nonscript\mkern-\thinmuskip{:}\mskip6mu
plus1mu\relax`, whose empty punctuation atom's 3mu is cancelled by the
negative kern behind it -- leaving an *ordinary* `:` with 2mu before
and 6mu after. Most documents that write `\colon` load amsmath.
Measured with TeX Live 2025 pdflatex at 10pt, control `\hbox{$ab$}` =
9.57755pt:
| box | no amsmath | with amsmath | delta |
| --- | ---: | ---: | ---: |
| `\hbox{$\colon$}` | 2.77779pt | 7.22212pt | +8mu |
| `\hbox{$a\colon b$}` | 14.02196pt | 16.79967pt | +5mu |
| `\hbox{$a\colon=b$}` | 24.57747pt | 30.13289pt | +10mu |
| `\hbox{$a\colon+b$}` | 21.79976pt | 29.0218pt | +13mu |
| `\hbox{$f\colon A\to B$}` | 41.55893pt | 44.33664pt | +5mu |
The 10mu and 13mu rows are the class in evidence, not just the glue:
the kernel's punctuation atom turns a following `+` into an Ord
(TeXbook Chapter 17's Bin-after-Punct rule) where amsmath's ordinary
one leaves it a Bin. The three-atom model this emits -- `space(2/18)`,
a `:` forced Ord, `space(6/18)` -- was checked against amsmath's own
expansion inside one document and is identical to the scaled point in
text, display, script and scriptscript style, and for `\colon` at a
formula boundary, before a relation, before a binary, and doubled.
## The mechanism
`MathPackages` is a `Copy` value carried by `MathParser` and passed to
`parse_tokens` / `parse_tokens_reporting_unclosed` as a required
parameter, so a caller cannot forget it and silently fall back to the
kernel. `parser::P` folds it from `\documentclass` and each
`\usepackage` name into a `math_packages` field -- the shape
`P::colors` and `P::font_encoding` already use, and the one that can
capture package *options* later, since the parser reads and drops them
in the same place. It is deliberately not a global: siunitx's
thread-local `Settings` is the mistake this does not repeat, and one
process compiles many documents. `siunitx::typeset`/`Context` take it
too, because `Context::math` re-parses synthesized unit formulas and is
the one path into the math parser with no document in scope.
Which packages and classes carry amsmath's definitions in was measured,
not assumed: each name was compiled with pdflatex and
`\hbox{$a a\colon b b$}` compared against the kernel expansion
(23.5995pt) and the amsmath expansion (26.37721pt) in the same
document, so font metrics cancel. Loading amsmath: `mathtools`,
`empheq`, `physics`, `nccmath`, `aligned-overset`, `cool`, `commath`,
`mismath`, `mhchem`, `chemformula`, and the `amsart`/`amsbook`/
`amsproc`/`acmart`/`beamer` classes. Measured as leaving the kernel's
alone, and so deliberately absent: `amsthm`, `amssymb`, `amsfonts`,
`amsopn`, `amsbsy`, `amscd`, `amstext`, `bm`, `unicode-math`,
`siunitx`, `esint`, `breqn`, `cases`, `mathdots`, `thmtools`, `braket`,
`cancel`, `tikz-cd`, `diagbox`, and the `article`/`report`/`book`/
`memoir`/`scrartcl`/`scrbook`/`scrreprt`/`revtex4-2`/`elsarticle`/
`IEEEtran`/`letter`/`proc`/`slides`/`amsdtx` classes.
`\colon` was previously diagnosed `\colon is not supported in math
mode` and typeset literally, so both definitions are new behaviour; it
joins the supported-LaTeX inventory and the generated artefacts are
regenerated.
`math::AtomClass` and `MathAtom::class_override` become public. The
render pipeline re-derives the forced class today by reading the
control word back out of the source at the atom's span
(`typeset::class_override_of`), which cannot tell `\colon`'s two
definitions apart -- they are the same five characters of source. The
sibling pipeline PR reads the field instead, behind its own feature.
## Gates
`cargo test --release` in `crates/compiler`: 444 passed, 0 failed,
against 441 passed / 0 failed at the same base (590fd86) in a separate
control worktree -- the 3 new tests, no other change. (`--test
robustness`'s `deeply_nested_input_does_not_blow_the_stack` overflows
in a *debug* build on this machine identically on both sides; release
passes on both.)
Real-world corpus (`tools/real-world-corpus/run.py --no-oracle`, this
checkout's binaries): 20 fixture/producer pairs, status, page counts
and exact diagnostic message sets identical to the control. hw1 and hw2
render 3 pages each, 0 errors, 0 overfull.
`crates/render-pipeline` vendors its own pinned copy of this crate
(`flashtex-compiler = { path = "vendor/compiler" }`), so nothing here
reaches `flashtex-render` until that pin moves; the render gates were
therefore also run through an *uncommitted* vendor swap, together with
the sibling pipeline change. amsmath corpus 59/59, amssymb 38/39
(`32-braces-narrow`, 1.012 bp, fails at this base too), both with zero
font diagnostics. Through that full stack `\hbox{$X a\colon b X$}`
renders within 0.0001 bp of pdflatex with and without amsmath.
Implementation-Agent: Claude Code engine-engineer (linux-primary, NixOS)
Commit-Executor: git via Claude Code
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
…th-package-context
`apps/mac/scripts/sync-supported-latex.sh --check` and `CompletionTests.testBundledInventoryMatchesTheCompiler` compare `apps/mac/Sources/FlashTeXMac/Resources/supported-latex.json` against `crates/compiler/supported/supported-latex.json` by sha256, so the editor's completion vocabulary never drifts from the compiler. The two were byte-identical at this branch's base (21eed5701677) and the previous commit regenerated the compiler-side copy, so the bundled one had to follow. Regenerated with the script, not by hand; the check now reports `bundled copy is current (23d25a1ff459)`. Implementation-Agent: Claude Code engine-engineer (linux-primary, NixOS) Commit-Executor: git via Claude Code Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
…context' into agent/kabir-claude/math-package-gating # Conflicts: # docs/user/compiler.md
`math::command_atom` applied the amssymb/amsfonts table unconditionally, so
`\square`, `\nleq`, `\mho` and the other 218 commands it answers rendered
happily in documents that never loaded the package. Probed with `\ifcsname`
under TeX Live 2025, base LaTeX2e has **no definition for any of them** and
pdflatex answers "Undefined control sequence", so this was a 1:1 divergence
across the whole table, not a few symbols.
Each symbol now carries the file that declares it (`amssymb::Provider`,
generated, not hand-written: `gen_amssymb.py` collects the declarations from
both `.sty` files before the dedup that used to hide `amsfonts.sty` 141-147's
re-declaration of `\square`, `\lozenge`, `\rightsquigarrow`,
`\vartriangleright`, `\vartriangleleft`, `\trianglerighteq` and
`\trianglelefteq`). `MathPackages` gains `amssymb` and `amsfonts` flags beside
`amsmath`, and `command_atom` diagnoses the missing `\usepackage` instead of
rendering. The regenerated table is byte-identical to the committed one apart
from the new field.
The same gate covers the four commands with their own arms rather than a table
row — `\varnothing`, the dashed arrows, `\mathbb`/`\mathfrak` and the obsolete
`\Bbb`/`\bold` (`\mathbf`, which `\bold` stands for, is the kernel's and stays
unconditional).
Negative behaviour, measured rather than assumed:
* `\angle` and `\hbar` are the two commands here base LaTeX2e *does* define,
as composites amsfonts replaces. Without the package they keep the kernel
advance: `\hbox{$\angle$}` 6.37344pt against amssymb's 7.22223pt, and
`\hbox{$\hbar$}` 5.76172pt against 5.40280pt. The `\hbar` composite
reproduces exactly from its pieces (macron 5.00002 + `\mkern-9mu` -4.99988 +
math italic h 5.76158). Neither changes atom class.
* Everything else in the table is diagnosed, because pdflatex errors.
Which package loads which was measured, not assumed: every candidate compiled
with pdflatex and probed for `\nleq` (amssymb only), `\ulcorner` (also
amsfonts) and `\binom` (amsmath). `txfonts`, `pxfonts`, `newtxmath`,
`newpxmath`, `mathabx`, `kpfonts`, `MnSymbol` and `cool` really do load
amssymb; `amsart`/`amsbook`/`amsproc` load amsfonts but not amssymb;
`acmart`/`beamer` load both. `libertinust1math`, `fourier` and `siunitx`
define part of the inventory themselves without either AMS package and are
deliberately absent.
Tier 1 of #198's audit, each measured before and after against pdflatex:
* `\pmod` inline opens with amsmath's `\mkern8mu`, not the kernel's 18mu:
`$a\pmod{y}$` 50.82503pt -> 45.26960pt, matching `$a\mkern8mu(...)$`
exactly. Display is 18mu under both (`\@displaytrue` puts amsmath back on
50.82503), so display formulas are untouched.
* `\bmod` is 5mu on each side, not the 4mu of its Bin class, under every
package: `$a\bmod b$` 34.29970 against an ordinary `mod` at 28.74428, and
`$\bmod b$` 24.56947 against 23.45839 where the Bin degrades to Ord.
* Text-mode `\,`/`\!` take amsmath's `.1667em` when amsmath is loaded: 20sp
wider at 10pt, 24sp at 12pt. `\:`/`\;` are identical under both, and the
math-mode `\mskip` forms do not move.
The inventory now records which package each symbol needs, so
`supported-latex.json` and the Mac bundled copy say "needs amssymb" where they
used to claim an unconditional symbol.
Gates, `crates/compiler` `cargo test --release`: **457 passed, 0 failed**
against **448 passed, 0 failed** at the base (62200c0 + #198) in the same
worktree; the +9 are this change's tests. Through an uncommitted full vendor
swap into `crates/render-pipeline`, the amsmath corpus is 59/59 and the
amssymb corpus 38/39 (`32-braces-narrow`, 1.012 bp, fails at the base too) —
**byte-identical output files** to the same swap of the base, with zero font
diagnostics. Every real-world fixture compiles with no new diagnostic: they
all load their packages, including through the `\usepackage{amsmath,amssymb}`
comma form.
Stacked on #198, whose `MathPackages` this extends; the merge of that branch
is the first parent commit here.
Implementation-Agent: engine-engineer (Claude Opus 5), linux-primary worktree
Commit-Executor: engine-engineer direct Git (Cursor usage-limit fallback)
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
`MathFontMetrics::extension_glyph` had no `SizeClass` parameter and
`CmMathMetrics` answered it at `SizeClass::Text` unconditionally, so a
provider could not be asked for family 3 at any other size. The two differ
whenever family 3 is not one fixed font: amsmath and amsfonts redeclare
`OMX/cmex/m/n` without `sfixed` (`ExtensionSizing::Designs`), where
`\textfont3` and `\scriptfont3` are different designs at different sizes.
The trait now takes `size`, `CmMathMetrics` honours it, and `make_brace` —
the only caller (`\overbrace`/`\underbrace` place `\braceld`..`\braceru`
directly) — passes `SizeClass::Text` explicitly, with the reason recorded at
the call site instead of being an unexplained constant.
Text is what pdfTeX does, measured rather than assumed: `\downbracefill`/
`\upbracefill` set the four pieces inside their own `$...$` (plain.tex
352-360), so they come from `\textfont3` of the current math size however
deeply the brace is nested in scripts. pdfTeX 3.141592653 (TeX Live 2025)
`\showbox` of an 11 pt article loading amsmath, where `\fontname\textfont3`
is `cmex10 at 10.95pt` and `\fontname\scriptfont3` is `cmex8`, places the
same `\hbox(1.31396+0.0)` piece from cmex10 at 10.95 pt for `\overbrace{a+b}`,
`x^{\overbrace{a+b}}`, `x^{y^{\overbrace{a+b}}}` and an `\underbrace` in a
fraction numerator; in `\footnotesize` all four come from cmex9 instead.
Passing the style's own size class would therefore have been a regression,
so the new test locks Text against `ExtensionSizing::Designs` (where a wrong
answer is cmex8, not cmex10) and against pdfTeX's 1.31396 pt piece height.
`crates/render-pipeline` implements this trait against its pinned
`vendor/math-layout`, so it is unaffected until that mirror is re-pinned; the
override there is a one-line signature change at that point.
`cargo test --release` on `crates/math-layout` (FLASHTEX_FONT_DIRS/
FLASHTEX_TFM_DIRS at apps/mac/Fonts), rebased on main a1c651a: 62 passed, 0 failed.
Implementation-Agent: Claude Opus 5 (engine-engineer subagent, vertical extensible assemblies lane, linux-primary)
Commit-Executor: Claude Code direct Git
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
…ts assemblies
`parse_vertical_variants` skipped `glyphAssemblyOffset` (it read the variant
records only), so Latin Modern Math's vertical glyph assemblies were never
loaded. A `\left(`/`\left[`/`\left\{`/`\left|`/`\left\lceil`/`\left\lfloor`/
`\sqrt` taller than every fixed cmex size is stacked by TeX from the
extensible recipe's top/middle/bottom/repeat pieces (tex.web §713), and those
cmex slots had no glyph mapping: `otf_gid` fell through to the size-chain
branch, so the top piece drew one small fixed variant and the rest drew
nothing at all, one `math_glyph_unmapped` warning each. A six-row
`\left[ array \right]` painted an 18 pt bracket where a 72 pt one belongs;
`\left|` painted twelve 12.02 pt bars stacked 6 pt apart.
Reading them:
* `parse_vertical_variants`/`parse_horizontal_constructions` become one
`parse_variants`, returning `minConnectorOverlap` (20 in Latin Modern Math)
and both axes' constructions with the same value type. Assembly parts are
a new `pub struct AssemblyPart` carrying the whole `GlyphPartRecord` —
`startConnectorLength`, `endConnectorLength`, `fullAdvance` and the
`fExtender` flag — which the horizontal path had been discarding.
* `MathFonts::vertical_assembly(ch, span, size)` builds the assembly for an
exact span: non-extender parts once, every extender repeated the same
number of times, one uniform overlap at every joint, at least
`minConnectorOverlap` and at most each joint's own
`min(end of the lower part, start of the upper)`; the repeat count is the
smallest that covers the span. Every Latin Modern Math vertical part draws
from its origin up to exactly its `fullAdvance`, so the result has ink from
0 to `span` and no seam.
* `TexMathMetrics::extensible_piece` recognises a placed cmex glyph as a
piece of the recipe ending that character's size chain (TeX never sets the
extensible character itself as a delimiter: `var_delimiter` switches to the
recipe as soon as it reaches an `ext_tag` character), and `otf_gid` maps it
to the part with the same role. The roles line up because both describe the
same delimiter: cmex's `rep` is the flagged extender, `bot`/`top` are the
outermost fixed parts, `mid` is the one between two extenders, and a
delimiter cmex builds without an end piece has none there either
(`\lceil`: extender then top; `\lfloor`: bottom then extender).
* `typeset::math_items` paints a whole stacked run as one assembly and one
cluster instead of piece by piece. Per-piece painting cannot work: the
font's parts are a different design from cmex's, so the extender's own
length (0.498 em for `(`, 1.202 em for `|`) is not cmex's 0.6 em repeat,
and the parts are held together by overlapping connectors rather than by
abutting boxes. The layout is untouched — the run's box is still exactly
the one TeX's `stack_extensible` produced.
Measured against pdfTeX 3.141592653 (TeX Live 2025) `\showbox`, 10 pt
`article`, `$\displaystyle\left<d> array6 \right<d>$` and friends, where
`array6` is a six-row `array`. The layout box was already pdfTeX's; what
changes is the ink that covers it ("before"/"after" are the painted extent,
from the v2 display list):
fixture pdfTeX box after (parts) before (painted ink)
\left( frac^3 \right) 36.00036 pt 36.00034 (4) 17.92 pt, 1 variant
\left( array6 \right) 72.00072 72.00070 (11) 17.92 pt, 1 variant
\left[ array6 \right] 72.00072 72.00070 (7) 18.00 pt, 1 variant
\left\{ array6 \right\} 72.00072 72.00073 (9) 11.00 pt, 1 variant
\left| array6 \right| 72.00072 72.00073 (7) 78.02 pt, 12 bars
\left\lceil array6 72.00072 72.00072 (7) 11.00 pt, 1 variant
\left\lfloor array6 72.00072 72.00072 (7) 18.00 pt, 1 variant
\sqrt{array6} 78.00077 78.00078 (11) 18.00 pt, 1 variant
\left( array10 \right) 120.00120 120.00119 (21) 17.92 pt, 1 variant
\Bigg\| 30.00030 30.00031 (3) 36.02 pt, 5 bars
The 2e-5 pt residual is the display list's 2^-20 bp tick quantisation. The
part counts are the font's, not cmex's, for the reason above. The ink spans
the box exactly in each case: the bottom part's baseline is the box's bottom
edge and the top part's ink top is the box's top edge (asserted in the new
`tests/extensible_delimiters.rs`).
Gates (FLASHTEX_FONT_DIRS/FLASHTEX_TFM_DIRS at apps/mac/Fonts), each compared
against a control build of this same base:
* amsmath oracle corpus: 59/59 within 0.5 bp (control 59/59).
* amssymb oracle corpus: 38/39 (control 38/39; `32-braces-narrow`, worst
1.012 bp, is a horizontal `\overbrace` case and fails identically before
and after).
* `cargo test --release` on `crates/render-pipeline`: 196 passed, 0 failed
(control on this base: 191; the 5 new tests are this change's. The
failing set is empty on both.)
* HW1: 3 pages, 0 errors, 6 warnings, no overfull diagnostic — byte-for-byte
the same diagnostics as the control. HW2: 3 pages, 0 errors, 9 warnings,
likewise unchanged.
* `fixtures/real-world` through the CLI: every fixture's status, page count
and error count unchanged; 9 `math_glyph_unmapped` warnings disappear
(`math-sheet` 7, `input-bibliography` 2) and nothing new appears. No font
diagnostic in any run.
Implementation-Agent: Claude Opus 5 (engine-engineer subagent, vertical extensible assemblies lane, linux-primary)
Commit-Executor: Claude Code direct Git
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
… too
Pipeline half of the package-gating lane. Compiler half is a separate PR, also
based on `main`.
`kern_command_text` asks `text_builtins::text_kern` which spelling produced an
`Inline::Kern` amount, to recover the control sequence inside a user macro's
replacement. That lookup assumed one amount per spelling. It is not: amsmath
renews `\thinspace`/`\negthinspace` to `.1667em` against the kernel's
`.16667em` — 20sp apart at 10pt and 24sp at 12pt, measured with TeX Live 2025
pdflatex (`\hbox{a\,b}` 12.22230pt against 12.22261pt, `\hbox{a\!b}` 8.88887
against 8.88857). The compiler now picks one from the document's packages, and
`text_kern` takes the flag as a required parameter so no caller can silently
fall back to the kernel.
This is a reverse lookup of a spelling for an amount already chosen, with no
document in scope, so it accepts either definition; the two amounts are
disjoint, so no spelling is claimed twice.
Behind the new `compiler-package-gating` feature, **off by default**, exactly
like `amsmath-inline` and `math-glyph-spans`: the two-argument `text_kern`
exists only in a compiler newer than the committed `vendor/compiler` pin, and
without the feature this calls the one-argument form as before. Turning it on
after the re-pin is a one-line default-feature edit.
Gates: `crates/render-pipeline` `cargo test --release` with
`FLASHTEX_FONT_DIRS`/`FLASHTEX_TFM_DIRS` pointed at the bundled Latin Modern
and its three rooted metric trees — **191 passed, 0 failed**, identical to a
control run of this branch's base in the same worktree. The feature path was
built and measured through an uncommitted full vendor swap of the compiler
branch: amsmath corpus 59/59, amssymb corpus 38/39 (`32-braces-narrow`, 1.012
bp, fails at the base too), with output files byte-identical to the same swap
of the base and zero font diagnostics.
Implementation-Agent: engine-engineer (Claude Opus 5), linux-primary worktree
Commit-Executor: engine-engineer direct Git (Cursor usage-limit fallback)
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
…th-package-gating-pipeline
…th-package-gating # Conflicts: # docs/user/compiler.md
…pported #180's sweep found 115 unsupported kernel math commands; #180 closed 10, #185/#186 50, #200/#201 33. The remaining 21 are 9 latexsym symbols, 7 cmex/cmmi/cmsy assembly pieces, \sqsubset/\sqsupset, \dddot/\ddddot and \mathscr. This adds the measurement that says what each one actually needs, and changes no crate. `measure.py` reproduces the method #200/#201 used: the width of \hbox{$\sym$} pins the family and slot a command is declared with, and the width of \hbox{$a\sym b$} against the $ab$ control (9.57755 pt at 10pt) pins its atom class, because the glue TeX inserts between two atoms is a function of the two classes alone. It prints the measured class beside the class the TeX source declares and flags disagreement; on TeX Live 2025 pdfTeX 3.141592653-2.6-1.40.27 all 20 measurable commands agree. `fontprobe.py` answers the other half — whether a bundled face can draw the glyph at that advance — over `apps/mac/Fonts`, through a small stdlib OpenType reader (`otfmath.py`: cmap 4/12, hmtx, MATH MathVariants). What the numbers establish: * The seven pieces are NOT extensible-assembly parts. They are plain \DeclareMathSymbol rows (fontmath.ltx 340, 374-377, 447-450) and are in nobody's MathVariants, so #227's AssemblyPart machinery is not their home. They already compose exactly — \hookrightarrow 11.11118 equals \lhook\joinrel\rightarrow, \mapsto 10.00002 equals \mapstochar\rightarrow, and likewise \hookleftarrow and \longmapsto — and not one of the seven can be painted at pdflatex's advance: \bracelu, \braceru, \lhook, \rhook and \mapstochar have no Unicode code point at all, while \braceld/\bracerd are U+23B0/U+23B1, absent from Latin Modern Math and 7.52000 pt in New Computer Modern Math against cmex's 4.50005. \mapstochar is zero width, which no OpenType glyph is. Latin Modern Math keeps these shapes only inside U+23DE/U+23DF's horizontal assembly, with the two middle tips welded into one 2003-unit glyph. Recommendation: diagnose all seven, draw none. * latexsym: aliasing to the usual amssymb equivalent is not harmless. \lhd, \unlhd, \rhd and \unrhd are \mathbin in latexsym and \mathrel in amssymb, so each moves 1.11111 pt regardless of font; \Join has no equivalent at all; \Box and \Diamond differ by +0.30556 and -1.25004 pt. Only \mho and \leadsto are exact. #201's +2.33327 pt \Diamond figure is reproduced (New Computer Modern Math U+25C7 10.25000 vs lasy's 7.91673) and Latin Modern Math turns out to have no U+25C7 at all. The README argues #201's option (b) with one change that removes its blocker: eleven advances measured from pdflatex are facts, not a font program, so nothing needs to be bundled or licence-verified — the repo already carries such constants for \varnothing and \smallint. * \sqsubset/\sqsupset are already closed twice over, in #212 and #230; this lane deliberately added nothing. They are the same advance and class under either package but a different design (ht/dp 5.39098/0.39098 under latexsym, 5.49860/0.35173 under amssymb), so package gating is a correctness requirement there, not hygiene. * \dddot/\ddddot are not accents: \dot and \ddot keep the nucleus width, \dddot{a} is 10.00038 pt where `a` is 5.28589, because amsmath 744-750 builds them as a \vbox of text-size roman periods over a \mathop. * \mathscr is an alphabet from an unbundled package, and mathrsfs and euscript disagree with each other (\mathscr{A} 10.31778 vs 7.70540); \mathcal is not a stand-in for either. Python 3 standard library only. pdflatex is an oracle only and is never in the product path; nothing here is a parity claim and no committed oracle data is regenerated. Implementation-Agent: Claude Opus 5 (engine-engineer, kernel math gap lane, linux-primary) Commit-Executor: Claude Code direct Git Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
`verbatim_display` expanded a tab to the next multiple of 8 columns. That encoded a text-editor convention, not pdflatex's behaviour, and PR #188 flagged it as a real mismatch in this crate's own Core-14 layout path. TeX has no tab stops at all. `latex.ltx`'s `\@vobeytabs` makes TAB active and `\let`s it to `\@xobeytab`, which is `\let` to `\@xobeysp` (`= \nobreakspace = \leavevmode\nobreak\ `); `verbatim*` re-points both through `\@setupverbvisibletab`. A tab is therefore exactly whatever one space is, with no dependence on the current column. Measured against pdfTeX 3.141592653-2.6-1.40.27 (TeX Live 2025), oracle only. `\showbox` of `<TAB>one` in `verbatim` yields a single `\glue 5.24995` (cmtt10 `\fontdimen2`, stretch and shrink both 0) — byte-identical to the one-literal-space baseline, not the eight glues the old rule implied. Glyph origins in the generated PDF, as offsets from the left text edge: source line measured one-space rule old 8-column rule <TAB>Q 5.23 bp 5.23 bp (1) 41.84 bp (8) ab<TAB>W 15.69 bp 15.69 bp (3) 41.84 bp (8) abcdefg<TAB>E 41.84 bp 41.84 bp (8) 41.84 bp (8) [agrees] abcdefgh<TAB>R 47.07 bp 47.07 bp (9) 83.99 bp (16) abc<TAB><TAB>T 26.15 bp 26.15 bp (5) 83.99 bp (16) <TAB><TAB><TAB>Y 15.69 bp 15.69 bp (3) 125.99 bp (24) `verbatim*` measures identically. Only the 7-column case agrees with the old rule, which is why it alone could not settle the question. Moved expectations, each justified by a number above: * `verbatim_expands_tabs_to_the_next_stop` asserted `lines[0].text == " ".repeat(8) + "a"` for a single leading tab. pdflatex puts `a` 5.23 bp from the margin, one cmtt10 cell, so the expectation is now `" a"`. Replaced by `verbatim_sets_a_tab_as_a_single_space_not_a_column_stop`, which also covers column 2, column 8 and two consecutive tabs — the cases that actually discriminate between the two rules. * Added `verbatim_star_sets_a_tab_as_a_single_visible_space`; the starred path had no tab coverage at all, and `\@setupverbvisibletab` makes a starred tab one visible space rather than eight. The middle dot for `\verb*`/`verbatim*` is kept, and the doc comment now says why it is legitimate rather than implying it is lossy. On pdfTeX `\verbvisiblespace` is `\asciispace` = `\char32`, and cmtt10 slot 32 is `/visiblespace` (U+2423 OPEN BOX). The Core 14 Courier face this crate lays out on has no U+2423, so a substitute is unavoidable; U+00B7 costs nothing geometrically because Courier's AFM width table is uniform and both `periodcentered` and `space` advance 600/1000 em (6.0 pt at 10 pt body size). `cargo test --release` in crates/compiler: 470 passed / 0 failed / 4 ignored, against 469 / 0 / 4 on a control checkout of the same base. The +1 is the one replaced test becoming two. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
Self-correction. The README claimed "all 20 measurable commands agree". The measured-vs-declared atom-class check actually covers 18: the nine latexsym symbols, \sqsubset/\sqsupset, and the seven pieces. All 18 still agree with zero mismatches -- only the count was wrong. \dddot/\ddddot and \mathscr were being counted as if they had a declared class to check. They do not: none of the three is a \DeclareMathSymbol, so measure.py reports their boxes and never claims a class for them. The README now says so. Implementation-Agent: Claude Opus 5 (engine-engineer, kernel math gap lane, linux-primary) Commit-Executor: Claude Code direct Git Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
…msmath
`make_big_delimiter` implemented only amsmath's `\bBigg@`: `\vcenter to
<factor>\big@size` with `\big@size` = 1.2 x the math strut. That is the
right rule *when amsmath is loaded*. The LaTeX kernel's own definition
(`fontmath.ltx` 513-520) is a different one, and it is what a document
without amsmath gets:
\big -> \left<d>\vbox to 8.5pt{}\right.
\Big -> \left<d>\vbox to 11.5pt{}\right.
\bigg -> \left<d>\vbox to 14.5pt{}\right.
\Bigg -> \left<d>\vbox to 17.5pt{}\right.
Two differences, not one. The lengths are absolute, so they do not follow
the body size; and the box is a `\vbox` (height `pt`, depth 0), not a
`\vcenter`, so Rule 19's delta is `max(pt - axis, axis)` rather than half
the target, and the result is floored at the vbox's own height.
The two rules coincide at 10pt and diverge everywhere else, which is why
this survived: every 10pt comparison agrees.
`\showbox` under pdfTeX 3.141592653-2.6-1.40.27 (TeX Live 2025),
`\hbox{$\displaystyle\Big[$}` in an `article`, as the box's height+depth:
| body | no amsmath | amsmath | before (either) |
|---|---|---|---|
| 10pt | 18.00017 | 18.00017 | 18.00017 |
| 11pt | 18.00017 | 19.71019 | 19.71019 |
| 12pt | 18.00017 | 21.60021 | 21.60021 |
So a 12pt document without amsmath set `\Big[` 6.00pt too tall, and
`\bigg[`/`\Bigg[` one cmex variant too far up the chain as well.
`Nucleus::BigDelimiter` now carries a `BigSizing` naming which definition
is in force instead of a bare `factor`. `Atom::big_delimiter` keeps its
signature and its meaning (the amsmath rule); `Atom::big_delimiter_kernel`
is the new one. Nothing selects the kernel rule yet -- that is the caller's
decision from the package list, and it belongs to the pipeline, which
builds against `vendor/math-layout` and so needs a re-pin first.
Measured: `tests/big_delimiters.rs` pins all 24 pdfTeX boxes (4 commands x
3 body sizes x both rules) to 1e-4pt. `cargo test --release` on
`crates/math-layout`: 65 passed, 0 failed (control on this base: 61 passed,
0 failed; the 4 new ones are this file).
`crates/render-pipeline` is untouched and builds against its pinned
`vendor/math-layout`, so the pipeline gates cannot move: HW1 3 pages /
0 errors / 6 warnings and HW2 3 pages / 0 errors / 9 warnings, and all
8 `fixtures/real-world` entries keep their status, page count and error
count, measured through the CLI on this base.
Implementation-Agent: engine-engineer (Claude Opus 5), linux-primary
Commit-Executor: engine-engineer direct git (Cursor usage limit fallback)
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
…rs all nine
Self-correction, and it reverses this lane's recommendation.
The first version of the README claimed aliasing the nine latexsym commands to
amssymb "changes the atom class of four of them", and recommended transcribing
eleven lasy10 advances as constants to avoid that. It also said \Join has no
amssymb equivalent at all. Both were wrong, and the error was reading
amssymb.sty without reading amsfonts.sty's compatibility block.
amsfonts.sty 151-162, guarded by
`\@ifpackageloaded{latexsym}{\@tempswafalse}{\@tempswatrue}`, provides all
nine itself when latexsym is not loaded -- and it keeps the kernel classes.
\lhd \unlhd \rhd \unrhd are re-declared \mathbin on the same AMSa slots the
\vartriangle* relations use, rather than \let to those relations, so the class
never changes. \Join is there too, at line 161, as a \mathrel composite of
AMSb "6F and "6E with \mkern-13.8mu.
Measured under \usepackage{amssymb} with no latexsym, every class is correct
and six of the nine are advance-exact: \mho, \leadsto, \lhd, \unlhd, \rhd and
\unrhd are all +0.00000 against lasy. Only three differ -- \Box +0.30556,
\Join +0.66690, \Diamond -1.25004.
So the recommendation becomes much cheaper and strictly more correct: provide
all nine through the amsfonts declarations gen_amssymb.py already parses,
gated on amssymb/amsfonts via #230's provider field. msam/msbm metrics are
already bundled and \mathbb already draws from msbm, so nothing new has to be
bundled, licensed or transcribed. The 1.11111 pt class error stays in the
README as the reason not to use the \vartriangle* names.
One exception the new table pins: with BOTH packages loaded, amsfonts leaves
latexsym's design alone for every name except \mho (lasy ht 6.83331 -> msbm
6.88889, advance unchanged), because amsfonts 101's \ams@DeclareMathSymbol is
`\global\let#1\undefined` then re-declare, an unconditional override sitting
outside the \if@tempswa guard. Load order does not change it.
measure.py grows a table for the nine under amssymb/amsfonts/both so every
number above is reproducible, and labels the old comparison as the naive alias
it is.
Implementation-Agent: Claude Opus 5 (engine-engineer, kernel math gap lane, linux-primary)
Commit-Executor: Claude Code direct Git
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
The page led with 'A - Engine + CLI' and put the native GUI second. The owner wants the compiler + IDE first and the engine-only CLI second, which also matches the landing page, whose primary button is Download for Mac and whose CLI link is the secondary 'Just the engine + CLI?' line. Sections swapped and relabelled; both anchors (#gui-install, #cli-install) keep their ids, so the landing page's CLI link and the first-launch note's 'install from the command line' link still resolve. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
Compiler + IDE first, engine-only CLI second, matching the landing page's primary button.
…sizing math-layout: size \big..\Bigg by the kernel's fixed lengths without amsmath
…tension-glyph-size math-layout: extension_glyph takes the size class it is asked for
…ing it
The README said the +4.71449 pt was "a thin space plus three cmr10 periods".
It is not: 4.71449 is the excess over the nucleus. The decomposition belongs to
the TOTAL advance, and it is exact -- \hbox{\,\normalfont...} measures
10.00038 and so does \dddot{a}; \hbox{\,\normalfont....} and \ddddot{a} both
measure 12.77817; the gap between the two accents is 2.77779, one cmr10 period,
to the last unit.
measure.py now builds those three boxes and prints them beside the accents, so
the claim is measured rather than asserted.
Implementation-Agent: Claude Opus 5 (engine-engineer, kernel math gap lane, linux-primary)
Commit-Executor: Claude Code direct Git
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
vendor/compiler's ea4ee5c (and every other checked pin) is an ancestor of main via `git merge-base --is-ancestor`, 150-2556 commits behind depending on the crate. The "ahead of main" framing nearly caused an integrator to treat a routine forward re-pin as dangerous. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
Recovers the sixteen `listings` fixtures (16..31) and the two oracle scripts from the unmerged PR #145 branch `agent/kabir-claude/verbatim-fidelity` (5a8d626), byte-identical, and adds `reference/*.json` regenerated with the local TeX Live 2025 pdflatex. Data only: no `.rs` changes, no engine code. PR #145's `listings.rs` was built on a font model main has since replaced and is deliberately not carried over; this is the oracle half so the engine can be rebuilt against real numbers. All sixteen compiled unmodified. None of them uses `\lstinputlisting`, so no `.c`/`.py`/`.java`/`.txt` data files are needed. Cross-check: the TL2025 references reproduce PR #145's TeX Live 2026 (MacTeX) references for all sixteen to <= 0.001 bp, with identical glyph text, font names, sizes, glyph counts and rule rectangles. reference engine: pdfTeX 3.141592653-2.6-1.40.27 (TeX Live 2025/nixos.org) invocation: pdflatex -interaction=batchmode, two passes, SOURCE_DATE_EPOCH=0 FORCE_SOURCE_DATE=1 Note for reviewers: `fixtures/verbatim/` did not exist on main at eea975c -- the sixteen non-listings fixtures (01..15, 32) and their references are still only on the unmerged branches `agent/kabir-claude/verbatim-fidelity` and `agent/kabir-claude/literal-verbatim-nfss`, so this commit adds the directory. `make_fixtures.py` still generates all thirty-two; running it here would create the sixteen that are not part of this change. Implementation-Agent: Claude Opus 5 (engine-engineer, linux-primary worktree) Commit-Executor: Claude Opus 5 (direct git, Cursor usage limit fallback) Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
`crates/render-pipeline/vendor/math-layout` was pinned at `ea4ee5c8`, **five math-layout commits behind main** — it was never re-pinned after #186 landed, so three merged PRs were inert in the pipeline. `git archive origin/main:crates/math-layout`, byte-identical to the real crate apart from `PIN`, per vendor/VENDORING.md. What the bump carries: - **#239** `BigSizing::{Kernel, Amsmath}` — the kernel's fixed `\big`..`\Bigg` lengths alongside amsmath's `\bBigg@`. `Atom::big_delimiter` keeps the amsmath rule, so this re-pin alone changes no output; selecting the kernel rule is the pipeline's job and is the next commit. - **#229** `MathFontMetrics::extension_glyph` takes a `SizeClass`. - **#186** 47 kernel math symbols with their cmsy/cmmi/cmr/cmex slots. - `2d652944` cmsy square relations boxed from their real TFM slots. - `c1702353` dotless letters share `\imath`/`\jmath`'s slots. - `b81a5414` `\bullet`/`\bigcirc` key off their cmsy slot's code point. #229's signature change lands on this crate's two implementors of the trait, which are pure delegators: `mathtex.rs` forwards to `CmMathMetrics` and `mathtext.rs` to its inner metrics. Both now forward `size`, as every neighbouring method in the same impls already does (`delimiter_extensible`, `radical_extensible`, `accent_sizes`). Taking the `_size` escape instead would have silently pinned family 3 to Text and quietly discarded the point of #229. Unblocks: #239's pipeline half (next commit). #227 (vertical assemblies) also builds against this mirror. Gates, NixOS linux-primary, bundled apps/mac/Fonts, FLASHTEX_TFM_DIRS = public/lm:jknappen/ec:public/amsfonts/symbols. Zero **font-failure** diagnostics (`font_unavailable`, `required_metrics_unavailable`, `ec_metrics_unavailable`, `font_outline_substituted`, `tfm_missing`, `math_font_unavailable`) — not zero diagnostics of any kind, since every corpus fixture legitimately reports `math_resource_profile`: | gate | control (main 9a82257) | after re-pin | |---|---|---| | render-pipeline --release --locked --no-fail-fast | 202 passed, 0 failed | 202 passed, 0 failed | | render-pipeline failing SET | empty | empty (identical) | | amsmath corpus | 59/59 within 0.5 bp | 59/59 | | HW1 / HW2 | 3 pages, 0 errors, 0 overfull | same | | real-world corpus (10 fixtures) | status/pages/diagnostic sets | identical to control | Implementation-Agent: Claude Opus 5 (integration lane, linux-primary / NixOS) Commit-Executor: Claude Opus 5 via Claude Code (direct-agent Git execution under the observed-Cursor-limit user override) Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
… absent The pipeline half #239 named as "the one thing here that is *not* done". math-layout models both sizing rules (`BigSizing::Kernel` / `::Amsmath`); choosing between them is a fact about the package list, which only this crate reads, and the math-layout lane was correctly barred from touching `vendor/`. - `Context::amsmath_loaded`, computed once in the constructor and carried on `TextSink::amsmath`, beside the existing `amsfonts`. Once, not per formula: a per-formula `\usepackage` re-scan is what made a whole-document render quadratic in (source size x formula count) — the FT-070 finding. - The `N::SizedDelimiter` arm picks `Atom::big_delimiter` (amsmath) or `Atom::big_delimiter_kernel` (the kernel's absolute `\vbox` lengths), mapping the compiler's 1.2/1.8/2.4/3.0 scale through math-layout's own `BigSizing::kernel_for_factor` rather than copying 8.5/11.5/14.5/17.5 into this crate. **`amsmath` is deliberately a separate predicate from `ams_symbol_fonts`.** That one is `amssymb || amsfonts` — the msam/msbm symbol fonts — and neither package loads `amsmath`. Reusing it here would apply amsmath's rule to a document that only wanted its symbols. The fix, `\Big[` in an article, as painted: | body size | before (no amsmath) | after | pdflatex | |---|---|---|---| | 10pt | cmex10 | cmex10 | fixed | | 11pt | cmex10, baseline 142.092 | cmex10, baseline 141.240 | `\vbox`, not `\vcenter` | | 12pt | **one variant further up the chain** | cmex10 | fixed | At 12pt the old code reached a visibly taller bracket than pdflatex sets; the 11pt baseline moves because Rule 19's delta is `max(pt - axis, axis)` for the kernel's `\vbox`, not half the target as for amsmath's `\vcenter`. New `tests/big_delimiter_packages.rs` (3): no movement with body size without amsmath, tracking with it, and that `amssymb`/`amsfonts` alone do not read as amsmath. The third asserts at the predicate, not through the painted glyph, because an `amssymb` document currently renders identically to an `amsmath` one for an unrelated reason — `amsfonts` redeclares `OMX/cmex/m/n` with several designs (`ExtensionSizing::Designs`, #204), and at these sizes both targets resolve to the same variant. Two mechanisms, two packages; the test says so rather than resting on the coincidence. Gates (control = main 9a82257 + the re-pin commit), zero **font-failure** diagnostics — `math_resource_profile` is expected on every corpus fixture and is not one: | gate | control | this commit | |---|---|---| | render-pipeline --release --locked --no-fail-fast | 202 passed, 0 failed | 205 passed, 0 failed | | render-pipeline failing SET | empty | empty (identical) | | amsmath corpus | 59/59 within 0.5 bp | 59/59 | | HW1 / HW2 | 3 pages, 0 errors, 0 overfull | same | | real-world corpus (10 fixtures) | status/pages/diagnostic sets | identical to control | Implementation-Agent: Claude Opus 5 (integration lane, linux-primary / NixOS) Commit-Executor: Claude Opus 5 via Claude Code (direct-agent Git execution under the observed-Cursor-limit user override) Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
vendor: re-pin math-layout to main, and select the kernel \big rule without amsmath (#239's missing pipeline half)
crates/render-pipeline/Cargo.toml already has `request-date` as a default Cargo feature, vendor/compiler (pin ea4ee5c) already carries parser::parse_project_with and date.rs, and apps/mac already sends `date: RuntimeV1.localDate()` on every compile request (ShellModel.swift). docs/contracts/runtime-v1.md, protocol/proposals/runtime-v1-request-date.md and two render-pipeline doc comments still described this as blocked on a vendor re-pin / off by default, which nearly reads as "\today still renders the epoch" today. crates/document-runtime does not send `date` yet; noted as still open. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
MISSING (the set of diagnostics that mark a fixture as a packaging failure) had tfm_missing/required_metrics_unavailable/font_unavailable/ math_font_unavailable but not ec_metrics_unavailable or font_outline_substituted, both real diagnostic codes emitted by crates/render-pipeline/src/typeset.rs (confirmed by grep) and both already treated as font-failure signals elsewhere (crates/render-pipeline/tests/ bundled_typewriter.rs's SUBSTITUTION_CODES, tools/visual-oracle/fontenv.py's FONT_DIAGNOSTIC_CODES). A build missing EC metrics or falling back to a substituted outline could pass this acceptance gate silently. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
…/Esc docs/user/gui.md and apps/mac/README.md described the completion list as opening only on an explicit Esc/⌃Space. apps/mac/Sources/FlashTeXMac/ Completion.swift (see the "MARK: automatic completion (typing opens the list; no ⌃Space needed)" section, opensAutomatically(), and automaticCompletionDelay = 0.05) has had automatic-open-while-typing for control words and completion-bearing argument keys; only plain prose words still require explicit ⌃Space. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
canonical-latex.tsv's candidates come only from the LaTeX2e reference manual's @findex/@EnvIndex entries and nine package source files (crates/compiler/scripts/canonical_latex.py); math symbols like \alpha and \odot are in neither, confirmed by `grep -P '\t(alpha|odot)$' canonical-latex.tsv` matching nothing. The coverage percentage was reading as overall LaTeX coverage when it actually excludes an entire supported category (509 math commands per dispatcher's count) that the compiler tracks through a separate mechanism (math.rs's COMMAND_GLYPHS/ OPERATOR_NAMES). Documented the gap rather than regenerating canonical-latex.tsv, which needs a TeX Live tree this box doesn't have. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
docs/user/compiler.md said "sans, typewriter and small caps are not bundled," but apps/mac/Fonts has had lmsans*/lmsansdemicond* (added in 9a22ae6), lmromanslant*/lmromancaps*/lmmonoslant*/lmmonocaps* (also 9a22ae6) and lmmono*/lmmonolt* (fa72dbf) for a while, and crates/render-pipeline/src/fonts.rs's latin_modern_file() resolves \textsf/\texttt/\textsl/small caps to those real files, not a substitution. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
#376) The residual after #302 was not a line count: typeset.rs added env_skip unconditionally, so the gap before the abstract head carried one whole \@topsep too many (+9.9994pt at 10pt, +11.9998 at 11pt = \topsep + \partopsep exactly). \@maketitle ends with \vskip 1.5em and \@item opens with \addvspace, which keeps the larger -- so after \maketitle the environment adds nothing. Same reading fixed the \if@nobreak branch (\@nbitem after a heading): a scratch probe went +12.960bp to +0.009. min-abstract -24.584 to -0.000 (93/93 aligned); plain-article -12.562 to +0.065; lab-report -11.801 to +0.005; hyperref-toc -10.209 to +0.004. article-twocolumn's bytes change deliberately, with evidence that the pre-existing bytes were wrong.
… reserves
Both options are ways of keeping an image's space without embedding the
file, which is why test documents use them: four corpus fixtures write
`\includegraphics[draft]` and two load `\usepackage[demo]{graphicx}`. We
honoured neither, so each of those graphics reserved nothing and the
document reflowed.
`demo` (`graphics.sty` `\DeclareOption{demo}`) replaces the whole of
`\Ginclude@graphics` with `\rule{\@ifundefined{Gin@@ewidth}{150pt}
{\Gin@@ewidth}}{\@ifundefined{Gin@@Eheight}{100pt}{\Gin@@Eheight}}`. No file
is looked up. `\Gin@req@sizes` -- the only thing that scales a natural size,
applies `keepaspectratio` and honours a leading `scale=` -- is never used,
so all that reaches the rule is what `\Gin@esetsize` left in
`\Gin@@ewidth`/`\Gin@@eheight`, and it reaches it literally: `[width=W]`
gives a `W` x 100pt rule, not a proportional one. From the first
`angle=`/`scale=` onwards the rule is wrapped in `\Gin@erotate`/
`\Gscale@@box` exactly as a real graphic is, and `keepaspectratio` does
apply there. `demo` beats `draft`, whose branch lives in `\Gin@setfile`,
which is never reached.
`draft` changes no dimension at all: `\Gin@setfile` still reads the file's
bounding box and still sets a box of `\Gin@req@width` x `\Gin@req@height`,
it just fills it with a frame of default-thickness rules and a `\rlap`ped
file name instead of the image. What it does change is a file that is not
there: `pdftex.def`'s `\Gread@pdftex` leaves the bounding box at `0 0 72 72`
and, under `draft`, warns instead of raising its package error -- so the
graphic reserves one inch square, scaled by the keys. That is where the
corpus divergence came from: all six fixture graphics name files that do
not exist. `draft` is now a key (`draft=false` turns it off for one
graphic), a package option, and a class option, since LaTeX passes the
class options to every package; a `final` anywhere cancels it, because
`\ProcessOptions` runs the declared options in declaration order and
`final` is declared after `draft`.
The reserved box is painted: a solid rule for `demo`, the four-rule frame
for `draft`. The frame's `\rlap`ped file name is not set yet -- it is
centred inside the reserved box and contributes no dimension -- and neither
placeholder is painted when an `angle=` has turned the box, since the wire
`Rule` item is axis-aligned. `trim`/`clip`/`viewport` stay recognised and
deliberately unhonoured; no field was added to the wire `Image` item.
Verified on linux-primary NixOS against a control build of origin/main
bca6ce5 in the same worktree and the same target directory, oracle
pdfTeX 3.141592653-2.6-1.40.27 (TeX Live 2025):
- 24 measured `demo` key combinations and the `draft` fallback size are
unit tests in `graphics.rs`; three end-to-end tests through a `figure`
are `tests/graphics_draft_demo.rs`.
- cargo test --release --locked --no-fail-fast: render-pipeline 244p/0f/1i
(control 241p/0f), compiler 498p/0f/4i (crate untouched).
- amsmath oracle 59/59 within 0.5 bp; tabular oracle 106/106 (words 0.5 bp,
rules 0.1 bp).
- HW1 and HW2 through `flashtex-render`: 3 pages each, 0 errors, 0
overfull, 0 font-failure diagnostics -- unchanged from control. (The
`flashtex-compiler` producer still reports HW2 as 4 pages; that
disagreement is untouched here.)
- real-world corpus vs control, `flashtex-render` producer: page-count
match 16/22 -> 19/22. article-twocolumn 1 -> 2 (= pdflatex 2),
hyperref-toc 3 -> 4 (= 4), lab-report 2 -> 3 (= 3). conf-paper 2 -> 3
(pdflatex 4, see below); thesis-chapter and twelvept-plain unchanged.
Render error-severity diagnostics 94 -> 89; no document gains an error.
Font diagnostics identical (only `missing_glyph`, same 20).
- conf-paper is still one page short for a reason that is not graphics:
its figure is a `figure*`, where pdflatex's `\linewidth` is `\textwidth`
(505.89pt) rather than the 243.91pt `\columnwidth` this engine resolves
it to, because a double-column float is not modelled. thesis-chapter's
and twelvept-plain's remaining page is also unrelated to graphics.
Implementation-Agent: engine-engineer (Claude Opus 5), linux-primary
Commit-Executor: this agent, direct Git under the observed Cursor-limit
fallback
Co-Authored-By: Claude Opus 5 <[email protected]>
Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
…erves (#377) Five of the six corpus page-count mismatches were these two options. draft does read the file (correcting the brief) -- what it changes is the MISSING-file case, where pdftex.def leaves the bounding box at 0 0 72 72 and warns instead of erroring; every corpus graphic names a file that does not exist, so that fallback is the whole effect. demo substitutes a rule, with height pinned at 100pt regardless of a given width, plus order-dependent scale/angle behaviour, all 24 combinations pinned as tests. Page-count match 16/22 -> 19/22 (article-twocolumn 1->2, hyperref-toc 3->4, lab-report 2->3). Gates: amsmath 59/59, tabular 106/106, render-pipeline 244/0, HW1/HW2 3 pages each via flashtex-render. CI: ubuntu render-pipeline, compiler and pdf all green.
…mily (#378) `\url{...}` was coming out in **roman**. The compiler already sets `TextFamily::Mono` on the runs it splits a URL into (`parser::push_url_text`), but the pipeline does not read that field: it re-derives NFSS from the source, scanning for `\texttt`/`\ttfamily` over their braced argument (`style_intervals`). `\url` was not in that table, so every URL was set in the body font. Measured against pdflatex (TeX Live 2025, 11pt `article`, T1, `\setbox0=\hbox{...}\the\wd0`), `\url{https://example.org/flashtex/emission-notes}`: | | pdflatex | before | after | |---|---|---|---| | `\url` | 243.80995pt | 211.42pt (roman) | **243.31010pt** | | `\texttt`, same string | 243.30995pt | 243.310pt | 243.310pt | 14 of 20 `\url`/`\nolinkurl` box widths over six URLs now match pdflatex to **0.0002 pt**. The six that do not are exactly the ones containing a hyphen: url.sty puts a **0.5pt kern after every `-`** (`\url{a-b}` 17.47511pt vs `\texttt{a-b}` 16.97511pt; `a-b-c` is 1.0pt wider — measured, two hyphens), which is a compiler-side change and is not in this PR. Two things make this a separate entry rather than a `text_font_command` row: - **The argument is opaque.** url.sty makes every character of a URL "other", and the compiler re-reads those bytes raw (`parser::url_argument`), so `%`, `#`, `_` and `\` inside a URL are literal. The style scan used to read them as LaTeX: a `%` in `\url{.../a%20b}` started a comment and swallowed the rest of the line, so a `\textbf{}` after the URL on that line silently lost its style. `url_argument_end` mirrors the compiler's brace rules byte for byte. - **The interval covers the whole command**, backslash through closing brace, because the compiler gives every run of a split URL the span of the entire `\url{...}` and the style is looked up at `span.start`. Corpus (`tools/visual-oracle/rank.py`, full `fixtures/real-world`, same binary directory before and after): **2 pages better, 0 worse, 58 unchanged**. `hyperref-toc` p3 max delta 426.113 -> 214.222 bp, reflowed 2 -> 1, aligned 228 -> 230; `listings-manual` p1 max delta 401.629 -> 87.319 bp, reflowed 21 -> 17. Isolating the document's other divergence (its `[demo]` `\includegraphics`, which pdflatex reserves 281.85587pt x 100pt for and this engine does not reserve at all — a graphicx gap, not a hyperref one) by substituting that exact box, `hyperref-toc` p2 words within 0.5 bp go 179 -> 191 of 193 aligned and p3 max |dy| 16.105 -> 2.595 bp. Gates: render-pipeline 241 passed / 0 failed; amsmath 59/59; tabular 106/106; HW1 and HW2 3 pages each with 0 errors and 0 overfull; zero font-FAILURE diagnostics. pdflatex is an oracle only and is never in the product path. Implementation-Agent: Claude Opus 5 (lane nixos-hyperref, linux-primary) Commit-Executor: Claude Opus 5 (direct git, observed Cursor usage limit) Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu Co-authored-by: Claude Opus 5 <[email protected]>
…ehind them (#380) `\citet`/`\citep` were unsupported, which is the second-ranked remaining gap on issue #2 and the most common one left: natbib is the default citation package for a large share of academic writing. On the `natbib-review` corpus document every citation was dropped, so the body reflowed around the holes — **29 reflowed words and a median +60.58 bp** on the minimal probe, and the abstract came out a line short because the four `\citep`s in it set nothing. New `crates/compiler/src/natbib.rs` implements natbib.sty 2010/09/13 8.31b (TeX Live 2025) as the three switches natbib itself uses — `\ifNAT@swa` (the delimiters wrap the whole list), `\ifNAT@par` (the delimiters are typeset at all) and `\NAT@ctype` (name+year / name / year) — so every command is a setting of those rather than its own formatter: | command | set | |---|---| | `\citet{kp}` | `Knuth and Plass (1981)` | | `\citep{kp}` | `(Knuth and Plass, 1981)` | | `\citealt{kp}` / `\citealp{kp}` | `Knuth and Plass 1981` / `Knuth and Plass, 1981` | | `\citeauthor{kp}` / `\citeyear{kp}` / `\citeyearpar{kp}` | `Knuth and Plass` / `1981` / `(1981)` | | `\citet*{jones}` | `Jones, Baker, and Williams (1990)` (the long author list) | | `\citet{plass81,hobby}` | `Plass (1981); Hobby (1986)` | | `\citep{plass81,hobby,frank}` | `(Plass, 1981; Hobby, 1986; Frank, 1990)` | | `\citep{plass81,plass90}` | `(Plass, 1981, 1990)` — same author, `\NAT@yrsep` | | `\citep{nosuch}` | `(?)` plus one warning, as `\@citex`'s `\bfseries ?` | **One optional argument is the post-note, not the pre-note** (`\NAT@citetp`, natbib.sty 688): `\citep[p.~7]{kp}` is `(Knuth and Plass, 1981, p. 7)` and only `\citep[see][p.~7]{kp}` puts "see" first. `\cite` is natbib's own redefinition of the kernel's (line 693): `\cite{kp}` is `\citet`, but `\cite[p.~7]{kp}` is `\citep` — the same asymmetry. `[`, `]` and `*` are ordinary word characters to the lexer, so `\citep[see][p.~7]` and `\citet*[p.~7]` each arrive as **one** `Word` token. `P::optional_bracket_argument` consumes whole tokens, so it read "see" and swallowed `[p.~7]` with it: the pre-note silently became the post-note and the post-note vanished. `P::cite_note_argument`/`P::take_cite_star` split the word instead, the way `skip_line_break_length` already does for `\\[3pt]x`. Package options are applied in **declaration** order, which is what `\ProcessOptions` (not the starred form) does: `numbers` re-executes `square,comma` and is declared before `round`, so `[numbers,round]` and `[round,numbers]` are both round with a comma separator, and `[authoryear, numbers]` is author-year either way. `numbers`/`authoryear`/`square`/`round`/ `angle`/`curly`/`comma`/`semicolon`/`colon`/`longnamesfirst`/`nonamebreak`/ `sectionbib`/`bibstyle`/`nobibstyle` are implemented; `sort`, `compress`, `sort&compress`, `super` and `openbib` are parsed, reported once each, and keep `\usepackage`'s "not implemented" warning. The bibliography side is what makes author-year possible at all. `natbib::parse_label` reads `\bibitem[Knuth and Plass(1981)]{kp}` and `[Jones et al.(1990)Jones, Baker, and Williams]{jones}` as `\NAT@bare` does (short author, year, long author) and `[Knuth, 1984]` as `\NAT@apalk` does. natbib's `\@lbibitem` also differs from the kernel's in two ways this now follows: **every** entry advances `\c@NAT@ctr`, labelled or not, and in author-year mode `\@biblabel` is `\hfill`, so the printed list carries no marker — `[1]` is gone from every entry. A `\bibitem` with no author-year data sets `\NAT@stdbst`, and `\NAT@force@numbers` then makes the whole document numeric on the next pass; that is reproduced, with natbib's own error text, because it is the steady state a two-pass pdfLaTeX run reaches (a probe that mixed one `[AWK]` label in silently turned every citation in this file numeric until the entry was removed). Verified against pdfLaTeX, not by inspection. Every string in `tests/natbib.rs` is what `pdflatex` (TeX Live 2025, `pdfTeX 3.141592653-2.6-1.40.27`) sets, read back out of the PDF's content stream, and the file's header table pins each form to the `\showthe\wd` of an `\hbox` around it (`\citet{kp}` 114.33638pt, `\citep[see][p.~7]{kp}` 160.02223pt, `\citep{plass81,hobby,frank}` 191.47311pt, ...) so a change that alters a character also alters a width someone can re-measure. `crates/compiler`: 528 pass, 0 fail, 4 ignored, including 30 new ones (`tests/natbib.rs` and `natbib.rs`'s own unit tests). amsmath oracle corpus 59/59 and tabular 106/106 unchanged. `docs/user/compiler.md`, `supported/supported-latex.json` regenerated by `crates/compiler/scripts/render_supported_latex.sh`; `tests/supported_latex.rs` 8/8, including the probe that compiles every inventory entry. With the companion render-pipeline PR, the `min-natbib` divergence probe goes from 29 reflowed words and a median +60.58 bp to **0 reflowed, max |dx| 0.03 bp**; `natbib-review` from 257 reflowed words across its three pages to 0; and `thesis-chapter`, the corpus's other natbib document, from 200 across its first four pages to 1. No page of any other corpus fixture is worse. The render pipeline reads this through `crates/render-pipeline/vendor/compiler`, which is a frozen pin: **a vendor re-pin is needed** before the pipeline build sees any of it. The pin is currently byte-identical to `crates/compiler` on main apart from its `PIN` file, so the re-pin is mechanical. Every measurement quoted here and in the companion render-pipeline PR was taken with that re-pin applied locally (not committed). Implementation-Agent: Claude Opus 5 (lane linux-natbib, linux-primary) Commit-Executor: Claude Opus 5 (direct git, observed Cursor usage limit) Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu Co-authored-by: Claude Opus 5 <[email protected]>
…wn spaces are control spaces (#381) Three things the pipeline had to learn once the compiler started setting natbib citations (companion PR, `crates/compiler`). Each is a separate measured defect; together they take `natbib-review` from **257 reflowed words across three pages to 0**. **1. `thebibliography` under natbib author-year is a hanging indent, not a label-width one.** natbib's `\@bibsetup` is `\NAT@bibsetup` (natbib.sty 642): `\leftmargin\bibhang` (`1em`, line 638) and `\itemindent-\leftmargin`, and its `\@biblabel` is `\hfill` — no label at all. The class rule the pipeline used (`\settowidth\labelwidth{\@biblabel{99}}`) put every entry **22.42 bp too far right**; pdfTeX starts each entry flush at the margin and hangs its continuation lines 10.909 bp in (`\the\bibhang` at 11 pt is 10.95003 pt, the body font's own `\fontdimen6`; 10.00002 at 10 pt, 11.74988 at 12 pt — so the new `ListMargin::Em` keeps it in `em` and resolves it against the font rather than the class's nominal size). `ListGeom::itemindent_em` carries the `\itemindent` that `\@labels` puts on the item's first line. This is gated on the entry's marker actually being empty as well as on the package options, so a build whose compiler still numbers bibliography entries keeps the class geometry instead of drawing a `[1]` on top of the hanging indent. The two PRs are therefore safe in either merge order. **2. Generated citation text is not the source's own bytes.** Every run of a citation carries the whole command's span, and `\citet{knuthplass1981}` is 22 bytes and sets exactly 22 characters — so the existing `exact` length test said "this is the source verbatim" and kept the blanks in "Knuth and Plass (1981)" as **blank glyphs** (LMRoman10's 0.5 em) instead of interword glue (cmr10's 0.33333 em). That is 1.825 pt too wide per space at 11 pt, and it accumulates: on the forms probe the word after a three-space citation sat 5.46 bp out, after six spaces 10.91 bp. `generated_citation` recognises the `\cite` family at the span and excludes it, exactly as `reference_spans` already excludes `\ref` and `\verb` output. **3. natbib's own spaces are control spaces.** `\NAT@spacechar` is `\ ` (natbib.sty 596) and the note's gap is normally a tie (`p.~7`), so the space factor of the character in front of them does not widen them. Ours were space *tokens*, so a `.` set `\spacefactor` to 3000 and added `\fontdimen7`: 1.2167 pt at 11 pt, which is exactly where "Jones et al. (1990)" and "(… , 1981, p. 7)" put a period in front of a space. Measured +1.216 bp on every such line before, 0 after. Measured with `tools/visual-oracle/rank.py` against the pinned TeX Live 2025 reference, `FLASHTEX_FONT_DIRS`/`FLASHTEX_TFM_DIRS` at `apps/mac/Fonts`, zero font-FAILURE diagnostics: | `natbib-review` | before | after | |---|---|---| | page 1 reflowed / max \|dx\| | 89 / 450.39 bp | **0 / 18.48 bp** (a math display, not a citation) | | page 2 reflowed / max \|dx\| | 108 / 446.79 bp | **0 / 0.91 bp** | | page 3 reflowed / max \|dx\| | 60 / 390.30 bp | **0 / 1.51 bp** | | page median shift (dx, dy) | (-0.21, -14.12) / (0.00, -27.10) / (+68.41, -22.52) | **(0.00, 0.00)** on all three | | words within 0.5 bp | 15 / 1 / 1 | **277 / 416 / 59** | A 32-form probe (`\citet`, `\citep`, both starred, `[pre][post]` in every combination, `\citealt`, `\citealp`, `\citeauthor`, `\citeyear`, `\citeyearpar`, `\cite`, multi-key, same-author, undefined, `\Citet`, `\citetext`, `\citefullauthor`, long author lists) aligns **201/201** words against pdfLaTeX with max |dx| 0.914 bp and 181 of them within 0.01 bp. What is left, and why it is not chased here: the 0.914 bp is natbib's `\NAT@nmfmt{\NAT@nm}` **group**, which ends pdfTeX's ligature/kern chain, so `{Hobby},` keeps the `y,` kern that `Hobby,` loses — `\showthe\wd` of the two is 34.37088 pt vs 33.45836 pt at 11 pt. Reproducing it needs a kern boundary inside a word, which the display list has no way to express today; it moves no line break in any fixture. The `min-natbib` divergence probe goes from 29 reflowed words and a median +60.58 bp to **0 reflowed, max |dx| 0.03 bp** (51 of 52 reference words aligned); `min-newblock` next to it is unchanged at 0.03 bp. `crates/render-pipeline`: 246 tests pass, 0 fail, 1 ignored with fonts configured, against the **pinned** vendor — 96 lib tests, was 94. HW1 and HW2 through `flashtex-render`: 3 pages, 0 errors, 0 overfull each, identical to the control build made in this same directory from `cc3232b4`. amsmath oracle corpus 59/59, tabular 106/106. Whole real-world corpus (57 compared pages, same harness and same directory for both builds): **8 pages better, 0 worse, 49 unchanged.** `natbib-review`'s three pages move from ranks 1-3 of 60 to 45/55/58, and `thesis-chapter` — the corpus's other natbib document — comes along with them: 200 reflowed words across its first four pages down to 1, max |dx| 424.09/435.00/426.51/436.21 bp down to 10.61/7.03/426.26/5.93. The citation text itself comes from `crates/render-pipeline/vendor/compiler`, a frozen pin: **a vendor re-pin is needed** for any of the numbers above to appear in a build from this branch alone. The pin is byte-identical to `crates/compiler` on main apart from its `PIN` file, so the re-pin is mechanical; every measurement here was taken with it applied locally and not committed. Implementation-Agent: Claude Opus 5 (lane linux-natbib, linux-primary) Commit-Executor: Claude Opus 5 (direct git, observed Cursor usage limit) Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu Co-authored-by: Claude Opus 5 <[email protected]>
… the supported-LaTeX artefacts after #380 and sync the Mac copy Conflicts were generated files only; regenerated with render_supported_latex.sh and copied the Mac bundled inventory byte-for-byte. Claude-Session: https://claude.ai/code/session_012c9XLkHjePPGBuarrmE2mz
…more dropped-frame warning (#311) (#336) * wip(#311): add failing boxed math frame regression Added an end-to-end render-pipeline test for inline and display \boxed frames, including four-rule geometry assertions and the dropped-frame diagnostic check. Ran: CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-boxed cargo test --manifest-path crates/render-pipeline/Cargo.toml --test boxed_math boxed_math_draws_frames_in_inline_and_display_math -- --nocapture Result: test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 measured; 0 filtered out. Next step: implement framed math through the existing math placeholder substitution path. Open questions: none; vendor copies remain read-only. Implementation-Agent: codex gpt-5.6-luna (max, cx slot plus) Commit-Executor: codex Lane-Owner: daniel-parent (mac-m5pro-dq222) * wip(#311): render boxed math frames Rendered compiler Frame::Box atoms through the existing math placeholder and MathBox::Rule paths. Box bodies are laid out in display style, framed with 3pt separation and 0.4pt rules, substituted with matching dimensions, and no longer reported as dropped. Added inline/display rule geometry assertions. Ran: CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-boxed cargo test --manifest-path crates/render-pipeline/Cargo.toml --test boxed_math boxed_math_draws_frames_in_inline_and_display_math -- --nocapture Result: test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out. Next step: run focused feature/source-span checks and the full render-pipeline suite, then self-review. Open questions: none; vendor copies remain untouched. Implementation-Agent: codex gpt-5.6-luna (max, cx slot plus) Commit-Executor: codex Lane-Owner: daniel-parent (mac-m5pro-dq222) * wip(#311): remove unused frame substitution wrapper Removed an unused public wrapper after the combined grid/frame substitution helper became the only call path. Ran: CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-boxed cargo test --manifest-path crates/render-pipeline/Cargo.toml --features math-glyph-spans --test boxed_math boxed_math_draws_frames_in_inline_and_display_math -- --nocapture Result: test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out. Ran: CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-boxed cargo test --manifest-path crates/render-pipeline/Cargo.toml --features math-glyph-spans --test math_glyph_spans -- --nocapture Result: test result: ok. 3 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out. Next step: run the complete render-pipeline suite after the implementation. Open questions: none. Implementation-Agent: codex gpt-5.6-luna (max, cx slot plus) Commit-Executor: codex Lane-Owner: daniel-parent (mac-m5pro-dq222) * wip(#311): keep math placeholder metadata aligned Reserved None key entries for grid and framed-box placeholders so TextSink::keys stays parallel with TextSink::texts, and narrowed the new frame-only helpers to crate scope. Ran: CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-boxed cargo test --manifest-path crates/render-pipeline/Cargo.toml --test boxed_math -- --nocapture Result: test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.10s Ran: CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-boxed cargo test --manifest-path crates/render-pipeline/Cargo.toml --test math_text -- --nocapture Result: test result: ok. 7 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.13s Ran: CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-boxed cargo test --manifest-path crates/render-pipeline/Cargo.toml --features math-glyph-spans --test boxed_math -- --nocapture Result: test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out; finished in 0.10s Next step: hand off the clean lane with the full-suite evidence from the prior implementation checkpoint. Open questions: none. Implementation-Agent: codex gpt-5.6-luna (max, cx slot plus) Commit-Executor: codex Lane-Owner: daniel-parent (mac-m5pro-dq222)
) The symbol table mapped them to the deprecated U+2329/U+232A, which NFC-normalise to CJK U+3008/U+3009; math-layout knows only U+27E8/U+27E9 (cmsy "68/"69), so the pipeline drew empty boxes ("no math glyph for '〈'"), and symbol_class did not list U+2329, so a bare \langle was spaced as Ord. \left\langle already used U+27E8. The base-14 path keeps its glyphs: Adobe Symbol names them angleleft and angleright at U+2329/U+232A, so export encodes U+27E8/U+27E9 as Symbol 0xE1/0xF1 and layout shapes them through the same substitution as the lunate epsilon. Refs #335, #258 rank 13 (fixtures/divergence-probes/min-langle) Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro) Commit-Executor: daniel-vpclaude (direct git) Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ
…art 2) (#303) `flashtex check`/`build`/`watch` print each diagnostic as a header, a `--> file:line:col` pointer, the source line(s) under a line-number gutter, carets under the byte span and a wrapped `= recovery:` line. - `--diagnostics=full|short|json`: full is the new form; short is the unchanged one-line `line_text`; json is `--json`. The default is full when stderr is a terminal and short otherwise, so piped output and scripts see exactly what they did before. - `--color=auto|always|never`; auto is on for a terminal unless NO_COLOR. - Uses only the fields a diagnostic already has (code, message, span, recovery). Structured labels/help from #277 part (1) can be added to the renderer without changing this path. - Spans: tabs expanded so carets line up, multi-byte text, empty spans and spans past the end of the text get one caret, spans longer than four lines show the first two and the last. Tests: 7 renderer unit tests, one end-to-end test for the flags. The pre-existing multi_file_project_resolves_inputs_from_the_project_root failure reproduces on unmodified main 9bd4b02 and is not touched here. Implementation-Agent: daniel-parent (mac-m5pro-dq222) Commit-Executor: git, direct
… not the fixture (#308) multi_file_project_resolves_inputs_from_the_project_root failed on main 9bd4b02: it asserted that fixtures/real-world/input-bibliography reports a diagnostic under sections/, and the compiler now supports everything in those files, so there is none. The engine is right (a diagnostic in an included file still names it: sections/a.tex:2:7). The fixture test keeps its closure, page and display-list checks. The path check moves to a_diagnostic_in_an_included_file_names_that_file, which writes a project with an unsupported command in sections/a.tex and asserts path, line and the stderr prefix. flashtex-cli: 6 unit + 13 integration, 0 failed. Implementation-Agent: daniel-parent (mac-m5pro-dq222) Commit-Executor: git, direct
* cli: a missing \input is reported once, not twice
`\input{missing}` produced `error[missing_file]` from project discovery and
`error[compiler]: included file not found` from the pipeline at the same
path and start byte, so one mistake counted as two errors. The pipeline's
duplicate is now dropped when a `missing_file` diagnostic already sits at
that position, and its recovery text moves onto the surviving entry.
Nothing else is deduplicated.
Test: a_missing_include_is_reported_and_the_build_still_writes asserts one
error line at main.tex:4:1, the recovery text, and summary.errors == 1.
flashtex-cli: 6 unit, 11/12 integration; the one failure is the fixture
drift fixed in #308 (fails identically on main 9bd4b02).
Implementation-Agent: codex gpt-5.6-luna (max effort, cx slot plus)
Commit-Executor: git, direct, by daniel-parent after review (renamed a shadowing binding)
Lane-Owner: daniel-parent (mac-m5pro-dq222)
Co-authored-by: d-q222 <[email protected]>
* cli: the missing-include dedupe also matches the compiler's own code
render-pipeline labels every compiler diagnostic "compiler" today
(display.rs from_compiler). Once it forwards the compiler's snake_case code
(#277 forwarding lane), "included file not found" arrives as
"recovered_input", and the dedupe would silently stop matching. Accept both.
cargo test -p flashtex-cli: unit 6/0; tests/cli 11 passed, 1 failed:
multi_file_project_resolves_inputs_from_the_project_root. That test also
fails without this change (control run, same branch), and #308 replaces its
fixture-dependent assertion.
Implementation-Agent: Claude Code (daniel-parent, mac-m5pro-dq222)
Commit-Executor: Claude Code (daniel-parent)
Lane-Owner: daniel-parent (mac-m5pro-dq222)
Claude-Session: https://claude.ai/code/session_012c9XLkHjePPGBuarrmE2mz
… is \@dbflt (#382) * render-pipeline: \twocolumn[\@maketitle] is \@topnewpage, floats or not On main a spanning title with floats on the page drew the full-width title and then set the column material *inside* it: `let shift = if floats.is_empty() { height } else { 0.0 }`, plus a warning saying the float path did not shorten the columns. Removing the condition alone is not the fix -- the shift and the shortening are one number and both have to reach the float placer. \@topnewpage (latex.ltx 20466-20505) boxes the optional argument at \hsize\textwidth with a trailing \vskip -\dbltextfloatsep, so \ht\@currbox is the material's natural height less \dbltextfloatsep; it then subtracts \ht\@currbox + \dbltextfloatsep -- the natural height exactly -- from \@ColhT, \vsize and \@colroom, and ends with \@floatplacement, which recomputes \@toproom, \@botRooM and \@fpmin from that reduced \@ColhT. \@combinedblfloats (21019) stacks the box, \vskip\dbltextfloatsep and the two-column box in one \vbox to\textheight, so the columns start the same natural height down that \@ColhT lost. Both columns of the page are shortened, because \@outputdblcol reaches \@outputpage (\global\@ColhT \textheight) only after the second one. Read off pdflatex's own \showoutput: \vbox(686.56499) = \vbox(108.18784) + 12 - 12 + 20 + \hbox(558.37715). So floatpage::paginate takes short_cols/short, Placer::set_colht drops \@ColhT for those columns and restores \textheight afterwards, and a float's graphics -- display-list items the placer had already put in page coordinates, unlike its caption lines -- take the same shift as the column they belong to. \@topnewpage's cap (\ht\@currbox > \textheight) and its "Optional argument of \twocolumn too tall" case are reported, not guessed at. \@makecol does not have two shapes, so floatpage no longer has two either: every column is packed \vbox to\@ColhT through pagebuild::make_column, not only a column carrying footnotes. That is what makes a \flushbottom column (\if@twocolumn \sloppy\flushbottom\fi) stretch its glue instead of standing at natural size; under \raggedbottom the \@textbottom fil keeps the natural positions, so single-column documents are unchanged. make_column in turn contributes \skip\footins, the \footnoterule and the notes only \ifvoid\footins\else: without notes the \vskip-\@outputbox@depth lands right after the body, so the body's last depth is outside \@ColhT. Those two were worth 3.726bp and 0.485bp of drift per paragraph on the new fixtures. fixtures/twocolumn-title (TeX Live 2025 on this Linux host, like fixtures/float-notes): the title alone 852/852 words, with a [t] float on page 1 957/957, with a float too large for the shortened column 1075/1075 -- all within 0.007bp, page counts exact. 04-title-figure-star is REPORTED, not gated, until the next commit: figure*/table* still reach the placer as single-column floats. flashtex-render vs each fixture's committed reference.pdf, page-1 median dy of matched words (control built in the same target directory, from cc3232b): article-twocolumn +37.057bp -> +4.257bp, page 2 -241.570 -> +0.010; conf-paper -118.696bp -> -0.000 (0 of 79 lines over 0.1pt), page 2 -246.718 -> -0.001. conf-paper's 2.25pt overfull_vbox on page 1 is gone, and so are plain-article's and thesis-chapter's; article-twocolumn's unsupported_block warning is gone. No other corpus fixture changes status, page count or diagnostics. Gates: amsmath 59/59, tabular 106/106, float-notes 10/10, footnotes 35/39 (unchanged), HW1 and HW2 3 pages each via flashtex-render with no error and no overfull, render-pipeline suite green. Implementation-Agent: engine-engineer (Claude Opus 5), linux-primary Commit-Executor: engine-engineer (Claude Opus 5), direct git under the observed-Cursor-limit fallback Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu * render-pipeline: figure*/table* are \@dbflt, not a wider figure conf-paper was a page short of pdflatex and the named cause was its figure*: floats.rs mapped `figure*` to a plain FloatKind::Figure, so \linewidth inside it resolved to \columnwidth (243.911pt) where pdflatex uses \textwidth (505.89pt), and the float was then placed in a column. Widening the box alone would have put a 505pt box in a 243pt column; the width and the placement are the same mechanism, and it is the one \@topnewpage already uses -- the page's spanning top area. \@float is \@dbflt \if@twocolumn (latex.ltx 17419). \@xdblfloat (17555) sets \hsize\textwidth \linewidth\textwidth, defaults the placement to [tp] rather than [tbp], and leaves the box depth at 1sp. That depth is the whole dispatch: \@testwrongwidth (21187) compares \dp\@currbox with \f@depth, which is \z@ everywhere except inside \@dblfloatplacement, so a full-width float is refused by \@addtocurcol, \@addtonextcol and \@startcolumn's \@tryfcolumn, and only \@addtodblcol (21280) takes it. That routine runs from \@startdblcolumn, after \@outputpage restored \global\@ColhT\textheight -- so it is once per page, never the page the float was written on, and its \@dbltoproom is \dbltopfraction of the full text height with \@textmin the rest. Each accepted box costs \@ColhT its height plus \dbltextfloatsep (the first) or \dblfloatsep, which is exactly the stack \@combinedblfloats (21019) builds above the columns, so the existing short_cols/short shift generalises to it unchanged. \dblfigrule is \relax in the kernel (21579). \@startdblcolumn tries \@tryfcolumn first, with \@fpmin \dblfloatpagefraction\textheight, and \@doclearpage's \if@twocolumn\if@firstcolumn branch flushes what is left the same way: a full-width float page takes every column slot of its page, and a half-finished page is closed with \@emptycol first. The box itself is built in a second Context over a \textwidth stylesheet and adopted, the route multicol already takes for a column's own \hsize -- Context::style is a shared reference and every block builder measures from it. LengthEnv grows a line_width beside text_width so \textwidth keeps meaning the whole block while \linewidth/\columnwidth/\hsize follow where the key is read; in a two-column document style.text_width_pt is \columnwidth, so the two were conflated before. conf-paper now sets 4 pages like pdflatex, with the figure* on a full-width float page of its own: page 1 median dy -0.000bp (0 of 79 lines over 0.1pt), page 3 -0.000, page 4 24/25 words matched at -0.069bp. Corpus page-count match against the references 19/22 -> 20/22 (the two remaining misses, thesis-chapter and twelvept-plain, are untouched by this). 04-title-figure-star is now gated: 1072/1072 words and its image rectangle within 0.007bp. Not modelled: nothing here changes a one-column document, where the star does nothing at all. Gates: amsmath 59/59, tabular 106/106, float-notes 10/10, floats 10/10, float-body 11/11, footnotes 35/39 (unchanged), page-frame 11/11, twocolumn-title 4/4, HW1 and HW2 3 pages each via flashtex-render with no error and no overfull, render-pipeline suite green. No corpus fixture regresses; plain-article and thesis-chapter each lose an overfull_vbox. Implementation-Agent: engine-engineer (Claude Opus 5), linux-primary Commit-Executor: engine-engineer (Claude Opus 5), direct git under the observed-Cursor-limit fallback Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu * render-pipeline: name the \@dbltoplist case the float placer does not model The previous commit's "not modelled" note was stale the moment it was written: `\@startdblcolumn`'s `\@tryfcolumn` *is* implemented, so a `[p]` full-width float does get a double float page. The case that really is not modelled is narrower -- a page that takes a `\@dbltoplist` box and whose first column `\@startcolumn` then fills with a single-column float page. LaTeX still combines the spanning boxes when that page ships; here the spanning area is attached to the next ordinary column. It needs a deferred `[p]` float and a deferred `figure*` at the same page boundary, which no fixture reaches, and guessing at it would be worse than saying so. Comment only; no behaviour change. Implementation-Agent: engine-engineer (Claude Opus 5), linux-primary Commit-Executor: engine-engineer (Claude Opus 5), direct git under the observed-Cursor-limit fallback Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu --------- Co-authored-by: Claude Opus 5 <[email protected]>
… (re-opened #310 onto main after #303 merged) (#387) * cli: rustc-style diagnostics with a source excerpt and carets (#277 part 2) `flashtex check`/`build`/`watch` print each diagnostic as a header, a `--> file:line:col` pointer, the source line(s) under a line-number gutter, carets under the byte span and a wrapped `= recovery:` line. - `--diagnostics=full|short|json`: full is the new form; short is the unchanged one-line `line_text`; json is `--json`. The default is full when stderr is a terminal and short otherwise, so piped output and scripts see exactly what they did before. - `--color=auto|always|never`; auto is on for a terminal unless NO_COLOR. - Uses only the fields a diagnostic already has (code, message, span, recovery). Structured labels/help from #277 part (1) can be added to the renderer without changing this path. - Spans: tabs expanded so carets line up, multi-byte text, empty spans and spans past the end of the text get one caret, spans longer than four lines show the first two and the last. Tests: 7 renderer unit tests, one end-to-end test for the flags. The pre-existing multi_file_project_resolves_inputs_from_the_project_root failure reproduces on unmodified main 9bd4b02 and is not touched here. Implementation-Agent: daniel-parent (mac-m5pro-dq222) Commit-Executor: git, direct Co-authored-by: d-q222 <[email protected]> * cli: fold per-font warnings into one entry, clear the terminal between watch rebuilds `--diagnostics=full` printed one entry per math font for the same `math_resource_profile` warning (4 of HW1's 6 diagnostics). Positionless diagnostics that differ only in a leading `name:`, wherever else the message repeats that name, now print as one entry listing every name: warning[math_resource_profile]: lmex10, lmmi10, lmmi8, lmsy10: glyphs drawn from latinmodern-math ... The summary counts, `--diagnostics=short`, piped output and `--json` are unchanged; nothing is hidden or reclassified. `watch` clears a terminal before each rebuild so the latest run is the only one on screen (piped stderr is untouched). Tests: 2 new unit tests (fold in place with the name repeated in the message; located, single and multi-word-name diagnostics never rewritten). flashtex-cli: 15 unit, 12/13 integration; the one failure is the fixture drift fixed separately in #308. Implementation-Agent: daniel-parent (mac-m5pro-dq222) Commit-Executor: git, direct Co-authored-by: d-q222 <[email protected]>
…in the preamble (GH#321) (#322) The remainder of #258's ranked finding 11. Probe min2-pagestyle declares \pagestyle{empty} in the preamble, and the compiler rejected it with "\pagestyle is not supported in the document preamble". The three commands already had body arms that are honest no-ops (there is no header or footer rendering yet), but those arms came after the `_ if has_document && !in_body => unsupported_preamble` catch-all. They now sit with the other preamble-or-body arms (\numberwithin, \sisetup, \graphicspath), unchanged. tests/preamble_page_commands.rs: all four preamble spellings report nothing and lay out identically to a preamble without them, and the committed min2-pagestyle probe compiles with no errors. Both tests fail against main's parser.rs and pass with this change. Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro plan) Commit-Executor: daniel-vpclaude, direct git (Cursor-limit fallback) Co-authored-by: d-q222 <[email protected]> Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ
…xt commands stop blaming math mode (#244) (#305) * compiler: \maketitle without \author warns like LaTeX; unsupported text commands stop blaming math mode GH#244, both parts. A. latex.ltx defines `\def\@author{\@latex@warning@no@line{No \noexpand\author given}}`, so a missing \author is a warning and the title block is still set. This compiler refused to produce any block and raised an error instead. - A missing \author now gives the warning "No \author given" and the title block, with no author line. - `\author{}`, or only blank \and slots, is an author that is given but empty. pdfLaTeX sets it silently, so there is no diagnostic. The issue asked for a warning in the \author{} case; the pdflatex oracle says there is none. pdflatex 1.40.29 oracle, `\the\pagetotal` after \maketitle: \author{A} 116.86673pt, no warning \author{} 115.33337pt, no warning no \author 116.86673pt, "LaTeX Warning: No \author given." The v1 layout still advances the author line in both empty cases. The 1.53 pt that pdfLaTeX gives back for \author{} is recorded, not modelled. B. Parser::unsupported is the text-mode fallback, but every message it emitted ended with "; unrestricted TeX math mode is not implemented". The message is now "\X is not supported by this compiler version". tests/acceptance.rs' "math ... reported" assertion was satisfied only by that misleading suffix on \tikz ($x^2$ has been implemented for a long time); it now asserts that nothing mentions math mode. Regenerated with their own ignored generators: RECOVERY.md and UNSUPPORTED.md. UNSUPPORTED.md also picks up an \includegraphics message that had changed earlier without a regen. Product path (parser.rs applied to render-pipeline/vendor/compiler locally, then reverted): fixtures/real-world/math-sheet goes from 1 error to 0 errors, 7 warnings, 2 pages (the reference has 2). HW1 stays at 3 pages / 0 errors / 7 warnings and HW2 at 3 / 0 / 8. Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro plan) Commit-Executor: daniel-vpclaude, direct git (Cursor-limit fallback) Co-authored-by: d-q222 <[email protected]> Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ * compiler: rustfmt the new maketitle tests Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro plan) Commit-Executor: daniel-vpclaude, direct git (Cursor-limit fallback) Co-authored-by: d-q222 <[email protected]> Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ
Two of the committed `reference.pdf` files were **two-pass builds of
documents that need three**, so the oracle we measure against was wrong
where it is easiest to be wrong: the page numbers in a table of contents.
| | committed | converged | wrong glyphs |
|---|---|---|---|
| `hyperref-toc` | `7758506be606` (pass 2) | `dfbfd4e366be` (pass 3 = pass 4) | **10** |
| `lmodern-report` | `319b433dcbc8` (pass 2) | `140f276b4a54` (pass 3 = pass 4) | **6** |
Every wrong glyph is a ToC or `\pageref` digit at the same position with a
different value — `hyperref-toc` listed a section that starts on page 2 as
page 1, on through "List of Figures" on page 3 that is on page 4. A
producer that got these *right* was scored as a mismatch.
`generate_reference` ran `for _pass in range(2)`. Neither the pass count
nor the rerun warning is the test:
- `hyperref-toc` pass 2 **does** warn ("Rerun to get"), and was written
anyway;
- `lmodern-report` pass 2 warns about nothing at all, and its pass 3 is
still a different document.
So the loop now runs until the PDF *stops changing* and pdflatex stops
asking, up to `MAX_ORACLE_PASSES` (6). A fixture that never settles is not
written at all and is reported — an unsettled reference is not a reference,
and silently keeping the last pass is how this got in.
`reference.json` gains `converged_after_passes`, and `argv` records
`(xN, to convergence)` rather than a hard-coded `(x2)`.
Swept all 22 fixtures for this: those two are the only ones. The other
seven whose bytes differ from a local rebuild are MacTeX 2026 references
being rebuilt with TeX Live 2025 — a different engine, not an unsettled
document — and each converges by the pass its sidecar claims.
Two tests cover the loop, and both fail against the old `range(2)`
(`2 != 4`, and a never-settling document silently producing a reference):
a late-settling document is run four times (three distinct, one to prove
the third was stable), and one that keeps asking for a rerun returns None
and writes nothing.
Harness tests 8 passed / 0 failed. pdflatex is an oracle only and is never
in the product path.
Implementation-Agent: Claude Opus 5 (Commander session, linux-primary)
Commit-Executor: Claude Opus 5 (direct git, observed Cursor usage limit)
Claude-Session: https://claude.ai/code/session_01Xd5Hmwh5GHNTiAmHUJ1MZu
Co-authored-by: Claude Opus 5 <[email protected]>
… suggestion (runtime-v1) instead of labelling everything "compiler" (#277) (#354) * wip(#277): reproduce from_compiler dropping code and suggestion Add display::Diagnostic.suggestion (None at every constructor) and tests that expect unknown_command/\alpha and unsupported_feature. from_compiler still hardcodes code "compiler" and does not copy suggestion. Ran: CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-diagfwd cargo test --manifest-path crates/render-pipeline/Cargo.toml --lib from_compiler_forwards Result: test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 measured; 89 filtered out display::tests::from_compiler_forwards_code_and_suggestion: left "compiler" right "unknown_command" Next: forward compiler code (explicit, else default_code, else "compiler") and suggestion; emit suggestion only in runtime-v1 JSON; extend corpus owner_for; keep v2 diagnostics without a suggestion key. Open questions: none in-scope. vendor/, apps, protocol schema untouched. Implementation-Agent: cursor-agent cursor-grok-4.6 Commit-Executor: cursor-agent Lane-Owner: daniel-parent (mac-m5pro-dq222) Co-authored-by: Cursor <[email protected]> * wip(#277): forward compiler diagnostic code and suggestion from_compiler copies the compiler's code (explicit, else default_code(message), else "compiler") and suggestion. runtime-v1 JSON emits suggestion only when set; display-list-v2 diagnostics are unchanged except the code value. owner_for accepts the compiler code set; tikz_pipeline rejects those codes too so a forwarded unknown_command cannot slip through as "not compiler". Ran (CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-diagfwd): - --lib from_compiler_forwards -- writer_matches_value_tree: test result: ok. 2 passed; 0 failed; 0 ignored; 0 measured; 88 filtered out - --lib write_json_matches_the_value_tree: test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 89 filtered out - --test compiler_diagnostic_forward: test result: ok. 2 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out - --test tikz_pipeline: test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out - python3 -m unittest tools.real-world-corpus.test_run: Ran 6 tests in 0.008s OK Next: full cargo test --manifest-path crates/render-pipeline/Cargo.toml control-vs-after. Open questions: no in-scope golden embeds "code":"compiler" for a compiler diagnostic (vendor/pdf fixture and apps/mac display-list fixture are out of lane). docs/user/compiler.md still shows the old example. Implementation-Agent: cursor-agent cursor-grok-4.6 Commit-Executor: cursor-agent Lane-Owner: daniel-parent (mac-m5pro-dq222) Co-authored-by: Cursor <[email protected]> * render-pipeline: from_compiler forwards exactly the compiler's code, no re-derived fallback Adopts the semantics of GoKubar's duplicate #370: the compiler's constructors already set `code` via `default_code`, and a `None` is deliberate (request validation), so re-deriving `default_code(message)` here could label a diagnostic the compiler's own runtime-v1 reply leaves uncoded. Now `d.code.map_or("compiler", ...)`. --lib from_compiler 1/0 (test updated: uncoded stays "compiler"); compiler_diagnostic_forward 2/0 (tikz still unsupported_feature, set by the compiler's constructor); tikz_pipeline 3/0; golden_v1 1/0. Implementation-Agent: Claude Code (daniel-parent, mac-m5pro-dq222) Commit-Executor: Claude Code (daniel-parent) Lane-Owner: daniel-parent (mac-m5pro-dq222) Claude-Session: https://claude.ai/code/session_012c9XLkHjePPGBuarrmE2mz --------- Co-authored-by: Cursor <[email protected]>
…ppet undo test (GH#256) (#318) testSnippetsInsertThroughTheRealTextViewAsOneUndoStep types \se through keyDown, which since #215 arms the automatic open on a 50 ms timer. It then presses ⌃Space, waits for any session, and presses Return. The timer's open and the ⌃Space open were two lifecycles racing, so Return could meet no session: the reported lastCloseReason .textChanged, no snippet, undo name "Typing". The test now fires the armed open deterministically (flushAutomaticCompletion, as AutomaticCompletionTests do). It then presses ⌃Space and waits until a session exists AND every scan either lifecycle scheduled has resolved (delivered + refusedStale + cancelled >= scheduled) before Return. Measured on mac-m5pro-dq222 under CPU load (8 busy processes): - original test: 1 of 5 runs failed; - this change: 5 of 5 passed (also 5 of 5 without load). Part 1 of #256, the live-compiler count pins in EditorDiagnosticsPartialOutputTests, was already fixed on main by 11ef11d's generated fixture. With a flashtex-compiler freshly built from main 5baa9e6, all 6 tests pass; no change is needed there. Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro plan) Commit-Executor: daniel-vpclaude, direct git (Cursor-limit fallback) Co-authored-by: d-q222 <[email protected]> Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ
…280) (#309) * mac tests: first-focus colouring and completion without a document switch (GH#280, probe) The regression tests #280 asks for. Each opens a document into a fresh editor with no document switch, then asserts that (a) the text carries syntax-colour temporary attributes, (b) typing \se through keyDown requests the list once and a real completion session opens, and (c) the typed command is coloured. Three hostings: - the bare SourceEditorView with the document present before mount; - the bare SourceEditorView with the document opened after mount; - the whole ContentView at the app's 1200x640 minimum size. All three pass on main 9bd4b02, so the owner's report does NOT reproduce under hosted conditions. Since the reported 8a5ac44 build, only 0f8ba91 (#300, popup appearance) has touched the editor sources. Ruled out by reading the code: view identity (EditorPane has no .id), the empty visible-window paint (window(for:) paints everything without a window), and diagnostic marks clearing the colours (MarkPainter removes only underline/tooltip keys). What remains differs between these tests and the bundled app: a key/active window, an attached producer delivering compile results, launch-time session/seed paths, and preferences such as Vim keybindings. Findings and questions are on #280. Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro plan) Commit-Executor: daniel-vpclaude, direct git (Cursor-limit fallback) Co-authored-by: d-q222 <[email protected]> Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ * mac editor: text typed at the edge of the painted window is coloured (GH#280) Measured cause. SyntaxPainter tracks `painted` ranges, the text whose temporary colours match the highlighter, and an edit's flush repaints only `painted ∩ dirty`. Its range arithmetic treated an edit that starts exactly at a painted range's end, or ends exactly at its start, as outside the range. Text typed at either edge was therefore never inside `painted` and never coloured. It only turned colour when something else repainted: a scroll, or a document switch, whose text reset repaints the window. That is the owner's "eventually comes" and "click another file and back". The startup document shows it directly. In the whole ContentView hosted like the app, with the caret at the end of the fixture text, typing " \se" left painted == [{0, 16}] over a 20-character text with 0 colour runs, while the highlighter held 1 run for \se. Fix: `shifted` joins edits that touch a range, using strict comparisons. The existing union branch already yields the right range for touching insertions and deletions; the new unit test pins eight cases. Tests (EditorFirstFocusTests): - testPaintedRangeAbsorbsEditsAtItsEdges and testStartupDocumentInContentViewIsColouredAndCompletes FAIL without this change and pass with it (verified by reverting only the source file); - the three earlier first-focus probes still pass. The completion half of the report did not reproduce: the list opens on first focus in every hosting. The owner's non-activating launch (window never key) is still to be checked in the real app. Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro plan) Commit-Executor: daniel-vpclaude, direct git (Cursor-limit fallback) Co-authored-by: d-q222 <[email protected]> Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ * mac tests: local focus probe for GH#280 (click + typing through window event dispatch) Skipped unless FLASHTEX_FOCUS_PROBE=1 because it takes keyboard focus. It hosts the whole ContentView in a window that was only ordered back, as in the owner's non-activating launch, then sends a real mouse click and real keyDown events through NSWindow.sendEvent. With #309 on this branch, the click gives the editor first responder (the window is still not key), the keys insert, typing \se opens a session, the CompletionPopup child window is visible, and the command is coloured. So completion on first focus does not reproduce through the real event path either. Left to check: app activation from an open -g launch, which a test process cannot emulate. Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro plan) Commit-Executor: daniel-vpclaude, direct git (Cursor-limit fallback) Co-authored-by: d-q222 <[email protected]> Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ
…otected, hosted tests don't start a second PadModel (#359) (#372) * wip(#359): regression test that concurrent CaptureQueue access crashes without a lock CaptureQueueTests.testConcurrentRefreshSendAndRecordsRead hammers refreshOutcome/send/draft plus tight records reads from Task.detached on two received captures (FakeMac + temp CaptureStore). Ran against unfixed CaptureQueue (HEAD 304120c, iPad Pro 11-inch M5 947A8CC1-07E2-4AA2-9363-FA389B569E8D): control unit suite first: Executed 25 tests, with 1 test skipped and 0 failures (0 unexpected) / ** TEST SUCCEEDED ** race test: Crash: FlashTeXPad at closure #1 in closure #1 in closure #2 in CaptureQueueTests.testConcurrentRefreshSendAndRecordsRead(); ** TEST FAILED ** (Restarting after unexpected exit, crash, or test timeout) Next: lock CaptureQueue._records and lastStoreError; isolate hosted XCTest PadModel; re-run this test then the suite. Implementation-Agent: cursor-agent cursor-grok-4.6 Commit-Executor: cursor-agent (this session, git commit) Lane-Owner: daniel-parent (mac-m5pro-dq222) Co-authored-by: Cursor <[email protected]> * wip(#359): lock CaptureQueue records; hosted XCTest PadModel skips Keychain/disk/polling CaptureQueue.records/lastStoreError/redeliveries are NSLock snapshots; update/draft/persistLocked run under the lock (store.save included). pollOutcome is @mainactor [weak self]. Hosted XCTestConfigurationFilePath PadModel() does not attach Keychain or CaptureStore and does not poll leftovers; FlashTeXPadApp skips auto-reconnect in that environment. Ran (iPad Pro 11-inch M5 947A8CC1-07E2-4AA2-9363-FA389B569E8D, iOS 26.5, Xcode 26.6): - unfixed race test: Crash: FlashTeXPad ... testConcurrentRefreshSendAndRecordsRead; TEST FAILED - after lock: race + hosted Executed 2 tests, with 0 failures; TEST SUCCEEDED - FlashTeXPadTests: Executed 27 tests, with 1 test skipped and 0 failures (control was 25 / 1 skip) - TSan -enableThreadSanitizer YES on race test and full suite: Executed 27 tests, 1 skipped, 0 failures; no ThreadSanitizer data-race reports - swift test in FlashTeXPadKit: Build complete! then error: no tests found (package has no test target by design) Next: lane-owner review / PR. Not switching CaptureQueue to actor/@mainactor (would hop off-main callers; current tests are @mainactor so it is feasible). Implementation-Agent: cursor-agent cursor-grok-4.6 Commit-Executor: cursor-agent (this session, git commit) Lane-Owner: daniel-parent (mac-m5pro-dq222) Co-authored-by: Cursor <[email protected]> --------- Co-authored-by: Cursor <[email protected]>
…314) (#317) * wip(#314): reproduce missing odot math symbol What changed: added a compiler spacing regression for a\\odot b. What was run: CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-odot cargo test --manifest-path crates/compiler/Cargo.toml --lib math::spacing_tests::odot_is_a_binary_operator -- --exact; test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 measured; 294 filtered out. Next step: add the compiler glyph and Bin-class mappings, then regenerate the supported inventory. Open questions: render-pipeline uses a read-only vendored compiler mirror and will need a separate integration re-pin. Implementation-Agent: codex gpt-5.6-luna (max, cx slot xedu) Commit-Executor: codex Lane-Owner: daniel-parent (mac-m5pro-dq222) * wip(#314): map odot to cmsy math symbol What changed: added COMMAND_GLYPHS and Bin-class mappings for odot, bound U+2299 to the pinned Latin Modern Math advance table at 778 font units, and regenerated the supported compiler inventory. What was run: CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-odot sh crates/compiler/scripts/render_supported_latex.sh; regenerated successfully. cargo test --manifest-path crates/compiler/Cargo.toml --lib math::spacing_tests::odot_is_a_binary_operator -- --exact; test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 294 filtered out. What was run: cargo test --manifest-path crates/compiler/Cargo.toml --lib export::tests::every_math_symbol_has_a_decided_export_outcome -- --exact; test result: ok. 1 passed; 0 failed; 0 ignored; 0 measured; 294 filtered out. cargo test --manifest-path crates/compiler/Cargo.toml --test lm_math_binding; test result: ok. 6 passed; 0 failed; 0 ignored; 0 measured; 0 filtered out. Next step: add the render-pipeline glyph-drawn regression and verify the pinned vendor limitation. Open questions: crates/render-pipeline/vendor/compiler remains read-only and needs a separate integration re-pin to consume this source fix. Implementation-Agent: codex gpt-5.6-luna (max, cx slot xedu) Commit-Executor: codex Lane-Owner: daniel-parent (mac-m5pro-dq222) * wip(#314): add odot pipeline regression What changed: added a render-pipeline regression that requires U+2299 to appear as a drawn math glyph with no odot diagnostic. What was run: CARGO_TARGET_DIR=/Users/dqi26/flashtex/target-odot cargo test --manifest-path crates/render-pipeline/Cargo.toml --test math_symbols odot_is_painted_as_a_binary_math_glyph -- --exact; test result: FAILED. 0 passed; 1 failed; 0 ignored; 0 measured; 10 filtered out. Observed failure: the read-only vendor/compiler mirror emitted a literal a\\odotb run and compiler:\\odot is not supported in math mode. Next step: integration must re-pin crates/render-pipeline/vendor/compiler (and its PIN) to this source change, then rerun the pipeline test. Open questions: no vendor files were edited per vendor/VENDORING.md; the existing pipeline warnings are unchanged. Implementation-Agent: codex gpt-5.6-luna (max, cx slot xedu) Commit-Executor: codex Lane-Owner: daniel-parent (mac-m5pro-dq222) * compiler: \ominus, \oslash and \bigcirc beside \odot; pipeline test waits for the re-pin The sibling cmsy circled operators had the same gap as \odot (#314): \ominus U+2296 ("09), \oslash U+2298 ("0B) and \bigcirc U+25EF ("0D), all \mathbin in fontmath.ltx, mapped by math-layout's cm.rs already. Added to COMMAND_GLYPHS, symbol_class (Bin), the vocabulary and the LM Math advances (778/778/1013 font units, measured with hb-shape from apps/mac/Fonts/latinmodern-math.otf); the spacing test covers all four; supported-latex inventory regenerated. odot_is_painted_as_a_binary_math_glyph is #[ignore]d: render-pipeline links the frozen vendor/compiler snapshot, so it can only pass after the integration lane re-pins vendor/compiler past this change. Tests (daniel-parent, own target dir): compiler lib 295/0, supported_latex 8/0. Worker-reported: lm_math_binding 6/0, export coverage 1/0, render-pipeline math_symbols 10/0/1 ignored. Implementation-Agent: codex gpt-5.6-luna (max, cx slot xedu) Commit-Executor: git, direct, by daniel-parent (worker sandbox could not write the git index on resume) Lane-Owner: daniel-parent (mac-m5pro-dq222) Co-authored-by: d-q222 <[email protected]> * apps/mac: sync the bundled supported-latex.json with this branch's compiler inventory The integration triage on #2 (5661305277) found this PR regenerates crates/compiler/supported/supported-latex.json without the Mac bundled copy, so CompletionTests.testBundledInventoryMatchesTheCompiler would fail once it lands. Merged current main (which carries #327's sync), regenerated with crates/compiler/scripts/render_supported_latex.sh, and copied the inventory byte-for-byte to apps/mac/Sources/FlashTeXMac/Resources/supported-latex.json. supported_latex 8/0. Commit-Executor: Claude Code (daniel-parent, mac-m5pro-dq222) Claude-Session: https://claude.ai/code/session_012c9XLkHjePPGBuarrmE2mz
siunitx loads array.sty (siunitx.sty 9321), so it joins ARRAY_PACKAGES.
With siunitx loaded, S[<options>] and s[<options>] are read as one column
specification item instead of one illegal character per letter. Both are
centred columns; plain numeric S entries are typeset through \num with the
column's options (table-* layout keys dropped) and plain s entries through
\unit. Braced, blank and command-bearing entries stay text, as siunitx sets
{...} entries. Decimal-marker alignment is not implemented and is reported
once per specification.
Clears every column-specification error in fixtures/real-world
siunitx-tables and lab-report. Syncs the Mac supported-latex.json copy,
which was stale since #251.
Refs #324
Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro)
Commit-Executor: daniel-vpclaude (direct git)
Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ
) and \pagestyle family (#322) parser arms parser.rs conflict: #322 added the pagestyle/thispagestyle/pagenumbering arms where this branch (carrying #276's commit) added allowdisplaybreaks; kept both. Regenerated supported-LaTeX artefacts and synced the Mac copy. Claude-Session: https://claude.ai/code/session_012c9XLkHjePPGBuarrmE2mz
Contributor
|
Superseded by #392: same commits rebased onto main after #317, #320, #322, #331 and #339 landed. All four conflicts were in generated output ( |
GoKubar
added a commit
that referenced
this pull request
Sep 14, 2026
…aracters (#243) (rebase of #304) (#392) * compiler: \( ... \) is inline math; \allowdisplaybreaks is a preamble no-op `\(` and `\)` fell through the lexer's control-symbol branch and became the literal words "(" and ")", so every LaTeX-style inline formula was typeset as text: `\(x_t\)` printed "(x" with "math script marker used outside math mode", `\(\alpha\)` reported \alpha as unsupported, and a 158-line notes document written entirely with \( \) came back with 129 errors. Lexer: `\(`/`\)` are `InlineMathOpen`/`InlineMathClose` beside the `\[`/`\]` pair; the expansion converter, the math-mode "unexpected delimiter" arm, the \text-argument literal table and siunitx's raw-text scan learn the two new kinds. Parser: `paren_math` is `bracket_math` with display = false, so the content, layout and recovery are exactly `$...$`'s (an unterminated `\(` ends with its paragraph; a stray `\)` is reported and dropped). `\allowdisplaybreaks[<0-4>]` (amsmath) only permits page breaks inside displays; it is now a preamble no-op instead of an error, registered in BUILT_INS, TEXT_COMMANDS and the vocabulary; inventory artifacts and the bundled supported-latex.json regenerated (kernel command count +1). Tests: tests/paren_inline_math.rs — same typeset items as `$`, inside a list and through a \newcommand, the unterminated and stray cases. Compiler suite 473 passed / 0 failed. Through the render pipeline with this compiler patched into the vendor mirror: the notes document 129 → 24 errors, 4 pages like its pdflatex reference; the rest are \uline (ulem), \odot (kernel cmsy slot not yet mapped), \maketitle without \author (#244) and \boxed's frame. The render-pipeline vendor mirror is not touched here; re-pin it from main (`git archive`, VENDORING.md) after this lands so the app and CLI pick it up. Implementation-Agent: Claude Code (mac-claude-a) Commit-Executor: git via Claude Code Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> Claude-Session: https://claude.ai/code/session_01Y1nAv4pEnmMYXgteBoadHn * compiler: text accents \c \v \u \H \r \k \d \b compose their dfu characters GH#243. Every letter-named text accent reported "\X is not supported by this compiler version"; only the control-symbol accents composed, and those only in render-pipeline's adapter. The issue named \c and \v, but \u \H \r \k \d \b failed the same way on main. One parser arm reads the argument the way TeX does: a braced single letter, \i, \j or nothing, or unbraced, the next letter only (so `\v sice` accents the s). It emits one text inline, spanning the command and its argument, holding the character tex-text-encoding's UNICODE_DECLARATIONS (inverted *.dfu) declares for `\<accent> <base>`. This is LaTeX's own table rather than a hand list. Two quirks of that table are handled: U+01F0 is spelled `\v\j` without the space, and the no-space spelling is tried only for control-sequence bases, since `\dh` is eth, not `\d h`. Recovery paths: - no declared character (`\b{a}`, `\c{x}`): the bare letter plus a warning. The \accent overlay is not drawn. - `\k` in OT1: LaTeX's "unavailable in encoding" error, then the letter. - a group that is not one letter: a warning, and the group is typeset. Inventory regenerated: kernel coverage 163 -> 171 of 410. The Mac copy of supported-latex.json is synced as the CI check requires. Known, pre-existing, not changed here: the v1 Times layout does not kern across inline boundaries, so `x\c{c}y` loses the x-c kern exactly as `x\o{}y` already does. The tests compare each accent in isolation. Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro plan) Commit-Executor: daniel-vpclaude, direct git (Cursor-limit fallback) Co-authored-by: d-q222 <[email protected]> Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ * compiler: text accents — wrap long lines, rustfmt the new test file No behaviour change. rustfmt cannot split the diagnostic format! strings, so the surrounding code lines are wrapped by hand. Crate-wide fmt --check and clippy -D warnings already fail on the base in files this lane does not touch (color.rs, expansion.rs, date.rs, ...); none of those findings are in the lines added here. Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro plan) Commit-Executor: daniel-vpclaude, direct git (Cursor-limit fallback) Co-authored-by: d-q222 <[email protected]> Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ * compiler: text accents — a document's own \v/\b definitions still win Math-heavy documents often \renewcommand{\v}[1]{\mathbf{#1}} or \def\b{...}. Making the accent letters host built-ins must not shadow those definitions; this test pins that the user's macro is expanded, not the caron. Gate evidence (no commit): with this lane's parser.rs and text_builtins.rs applied locally to render-pipeline/vendor/compiler and then reverted, `flashtex check fixtures/real-world/unicode-accents/main.tex` went from 2 errors to 0 errors, 22 warnings (CJK/glyph coverage). In the v2 display list, fa\c{c}ade and Ko\v{s}ice are 32.847 bp and 33.506 bp wide, the same as the precomposed façade and Košice on the line above. Implementation-Agent: daniel-vpclaude (Claude Code, Claude Pro plan) Commit-Executor: daniel-vpclaude, direct git (Cursor-limit fallback) Co-authored-by: d-q222 <[email protected]> Claude-Session: https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ --------- Co-authored-by: jay3332 <[email protected]> Co-authored-by: Claude Opus 5 (1M context) <[email protected]> Co-authored-by: d-q222 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #243. Lane
daniel-vpclaude(Claude Pro, mac-m5pro-dq222), allocated by the Commander on #2 at 04:23Z. Stacked on #276 as instructed: the base isagent/mac-compiler/paren-inline-math, so this diff holds only the accent change.What
Every letter-named text accent failed with
\X is not supported by this compiler version. That covered\cand\v, which the issue named, and also\u\H\r\k\d\b, which the issue believed already worked. Only the control-symbol accents (\'\"…) composed, and only in render-pipeline's adapter.One parser arm now reads the argument the way TeX does:
\i,\j, or an empty group;\v sicegivesšice.It emits one text inline holding the character that
tex-text-encoding'sUNICODE_DECLARATIONS(the inverted*.dfutablestext_symbolalready uses) declares for\<accent> <base>. That makes the mapping LaTeX's own rather than a hand list.Table quirks handled: U+01F0 is spelled
\v\jwith no space. The no-space spelling is tried only for control-sequence bases, because\dhis ð, not\d h; the first draft got that wrong and a test caught it.Recovery:
\b{a},\c{x})\accentoverlay isn't drawn\kunder OT1Command \k unavailable in encoding OT1error, then the letter\v{cz})\vwith nothing after it\renewcommand{\v}/\def\bEvidence
tests/text_accents.rs: 8 new tests. Layout matches the typed precomposed input word for word (text, x, baseline, size, and diagnostics including glyph-coverage warnings), plus the unbraced form, every accent family, T1 vs OT1, and each recovery path.cargo test -p flashtex-compiler: all 31 test binaries pass, 0 failures.parser.rs/text_builtins.rstorender-pipeline/vendor/compiler, rebuiltflashtex, then reverted.flashtex check fixtures/real-world/unicode-accents/main.texgoes from 2 errors to 0 errors. The 22 remaining warnings are CJK and glyph coverage.fa\c{c}ade= 32.847 bp andKo\v{s}ice= 33.506 bp, identical to the precomposedfaçade/Košiceon the line above.hw1_preambleandhw2_gatepass. Across the corpus onlyunicode-accentsuses them.supported-latex.jsonis synced as CI's check requires.fmt --checkandclippy -D warningsalready fail on the base in untouched files (color.rs,expansion.rs,date.rs, …); CI enforces neither.Not in this PR
crates/render-pipeline/vendor/compileris re-pinned. VENDORING.md keeps vendor read-only in feature PRs. I can open the re-pin PR after merge if you want (compiler:\|/\Vert/\lVert/\rVertare U+2016, not two\mids #265 → vendor: re-pin compiler past #265 so \| stops rendering as two \mid glyphs #274 precedent).x\c{c}ymisses the x–ç kern just asx\o{}yalready misses x–ø, by about 0.1–0.2 pt. pdfLaTeX under T1 keeps it.\t(a tie over two letters) and the\accentoverlay for letters with no precomposed form.🤖 Generated with Claude Code
https://claude.ai/code/session_012iWhnaQddU1UTMh6ZssGBJ