Files
pdfcraft/crates/forms/src
jonathanwxh-cellandskylar taylor-barrick 7895411b03 fix(forms): name detected check boxes from the nearer neighbouring label (#2943) (#2953)
* fix(forms): name detected check boxes from the nearer neighbouring label (#2943)

* M6: bound rectangle work during form detection (#2953)

Limit drawn and existing rectangle candidates before pairwise comb and checkbox work, preserve every widget overlap exclusion, and avoid cubic default-name lookup. Document partial proposals on unusually complex pages.

Verified: 143 forms unit tests, strict forms clippy, wasm check, layers, assets, and format. The count-based regression fails when the pre-comb cap is removed.

* Bound existing-widget overlap work during field detection

Index every existing widget spatially and cap aggregate query work, rejecting unchecked proposals if adversarial geometry exhausts the budget. Retain exclusions beyond the proposal/label budget.

Add synthetic 100k-widget, inverted-geometry and linear-equivalence regressions. The original linear scan fails the new work-bound negative control. All 147 forms tests, strict Clippy, formatting, wasm, layers and assets checks pass.

---------

Co-authored-by: skylar taylor-barrick <hi@skylar.cc>
2026-11-18 00:15:31 -06:00
..
2026-11-12 18:15:19 +01:00
…