Implements the span layer renderer for the inspector debug viewer. Renders SVG outline rectangles for each text span, color-coded by extraction confidence. Red (< 0.5), yellow (0.5-0.8), and green (> 0.8) indicate low, medium, and high confidence respectively. Gray indicates direct extraction without OCR. Each rect includes data-* attributes for tooltip and click consumption: - data-text: the extracted text content (XML-escaped) - data-confidence: confidence score or empty string - data-font: font name (XML-escaped) - data-size: font size in points All 10 unit tests pass. The implementation follows the existing SVG generation pattern in pdftract-core/src/receipts/svg.rs. Closes: pdftract-p4vzu |
||
|---|---|---|
| .. | ||
| src | ||
| tests | ||
| build.rs | ||
| Cargo.toml | ||
| pdftract-cli.cdx.json | ||