Some checks failed
cad / cad-truth-gates (push) Has been cancelled
cad / cad-core-checks (push) Has been cancelled
cad / cad-consumers (push) Has been cancelled
doc-engine / engine (push) Has been cancelled
doc-engine / coverage (push) Has been cancelled
doc-engine / consumer (push) Has been cancelled
email / gates (push) Has been cancelled
email / email-domain (push) Has been cancelled
email / nigig-email (push) Has been cancelled
email / supply-chain (push) Has been cancelled
nigig-build (CAD) / supply-chain (push) Has been cancelled
nigig-build (CAD) / cad-module (push) Has been cancelled
nigig-build (CAD) / full-crate-check (push) Has been cancelled
nigig-build (CAD) / cad-engine-coverage (push) Has been cancelled
nigig-build (CAD) / doc-workspace-coverage (push) Has been cancelled
nigig-build (CAD) / cad-widget-coverage (push) Has been cancelled
nigig-map / test (push) Has been cancelled
nigig-site / Owned paths and honest test contracts (push) Has been cancelled
nigig-site / Cargo check-all-targets (push) Has been cancelled
nigig-site / Cargo clippy-site-owned (push) Has been cancelled
nigig-site / Cargo contained-media-export-fixtures (push) Has been cancelled
nigig-site / Cargo containment-storage-crypto (push) Has been cancelled
nigig-site / Cargo core-clippy (push) Has been cancelled
nigig-site / Cargo core-contracts (push) Has been cancelled
nigig-site / Cargo integration-non-live (push) Has been cancelled
nigig-site / Cargo production-dependency-containment (push) Has been cancelled
nigig-site / Cargo site02-crypto (push) Has been cancelled
nigig-site / Cargo site02-repository (push) Has been cancelled
nigig-site / Cargo site02-store (push) Has been cancelled
nigig-site / Cargo unit (push) Has been cancelled
nigig-site / SITE-02 native provider/filesystem (macos-latest) (push) Has been cancelled
nigig-site / SITE-02 native provider/filesystem (ubuntu-latest) (push) Has been cancelled
nigig-site / SITE-02 native provider/filesystem (windows-latest) (push) Has been cancelled
nigig-site / SITE-02 desktop runtime and normal shutdown (push) Has been cancelled
nigig-site / SITE-02 migration, recovery, and fault corpus (push) Has been cancelled
nigig-site / Media limits (explicitly skipped until enabled) (push) Has been cancelled
nigig-site / Real server interoperability (explicitly skipped until enabled) (push) Has been cancelled
nigig-site / Security and supply-chain baseline (push) Has been cancelled
repo hygiene / hygiene (push) Has been cancelled
sms / gates (push) Has been cancelled
sms / robius-sms (push) Has been cancelled
sms / android (push) Has been cancelled
sms / nigig-sms (push) Has been cancelled
sms / supply-chain (push) Has been cancelled
spreadsheet / engine-coverage (push) Has been cancelled
spreadsheet / ui-controller-coverage (push) Has been cancelled
traffic / gates (push) Has been cancelled
traffic / nigig-traffic (push) Has been cancelled
traffic / supply-chain (push) Has been cancelled
nigig-site / Release capability gate (push) Has been cancelled
- providers/tesseract: system tesseract (TSV → text + normalized word boxes), installed-language detection; default_engine() picks Vision/Tesseract/none - image_prep: decode, validate, apply rotation before recognition - jobs: background OcrJob with progress, cancel, per-item results - ui_state: no fake success toasts; clipboard/export/share report real outcomes - ingest: real decode validation, size caps, shared PDF pages (no duplication) - export: atomic writes, paginated multi-page PDF, refuse non-WinAnsi text - capture: fixed drag anchor; settings: atomic save + applied to new files - drop unused deps; tests: 78 pass incl. 5 real-OCR on a fixture - EXECUTION_PLAN: correct overstated status
51 lines
2.3 KiB
TOML
51 lines
2.3 KiB
TOML
[package]
|
|
name = "nigig-ocr"
|
|
version = "0.1.0"
|
|
edition = "2021"
|
|
license = "MIT OR Apache-2.0"
|
|
description = "Rust + Makepad port of OCR Tool PRO 1.0 (Moneyplant) — tiny binary via OS-native OCR APIs."
|
|
|
|
# Reuse-first feature layout (see EXECUTION_PLAN.md):
|
|
# - `engine`: pure-Rust types + OcrEngine seam. Reuses nigig-pdf-document::ocr
|
|
# (OcrWord/OcrLayer) and nigig_doc_scanner::scanner_core (preprocess).
|
|
# No UI, no model download — keeps binary small.
|
|
# - `app`: Makepad UI shell (DropView, Image+Overlay, TextView, toolbar).
|
|
# - `default = ["engine", "app"]`: building/running the app itself.
|
|
# - `system-ocr`: allow OS-native providers (Vision on Apple, WinRT on
|
|
# Windows). Off by default so `cargo check` stays host-free; enable per-target.
|
|
[features]
|
|
default = ["engine", "app"]
|
|
engine = []
|
|
# Only what the shell actually uses. nigig-core/uikit/pdf-document were
|
|
# declared but never referenced (OCR-T1 audit) and dragged a network stack
|
|
# into an "offline, tiny" binary. Re-add each when code really uses it.
|
|
app = ["dep:makepad-widgets"]
|
|
# OS-native providers. Must enable the optional bindings, otherwise the
|
|
# Apple provider can never link (OCR-T1 fix).
|
|
system-ocr = ["dep:objc2", "dep:objc2-foundation"]
|
|
|
|
[[bin]]
|
|
name = "nigig-ocr"
|
|
path = "src/main.rs"
|
|
required-features = ["app"]
|
|
|
|
# Headless engine demo (P9): drop→OCR→overlay→export without a display
|
|
# server. Builds on `engine` only so desktop flow runs anywhere.
|
|
[[bin]]
|
|
name = "nigig-ocr-demo"
|
|
path = "src/bin/nigig-ocr-demo.rs"
|
|
|
|
[dependencies]
|
|
makepad-widgets = { workspace = true, optional = true }
|
|
image = { version = "0.25", default-features = false, features = ["png", "jpeg"] }
|
|
|
|
# Apple Vision binding — macOS/iOS only, dynamic system framework (no size cost,
|
|
# same reason the Swift original is 1.1M). Kept behind `system-ocr` + target cfg.
|
|
[target.'cfg(target_vendor = "apple")'.dependencies]
|
|
objc2 = { version = "0.6.1", optional = true }
|
|
objc2-foundation = { version = "0.3.1", default-features = false, features = ["std", "NSString"], optional = true }
|
|
|
|
# NOTE: no `makepad-test` dev-dep while the pinned fork's `makepad-test`
|
|
# checkout fails to compile (pre-existing, unrelated). UI coverage runs via
|
|
# the headless `UiState` mirror (`src/ui_state.rs`, `tests/parity.rs`,
|
|
# `tests/makepad_ui_plan.rs`); re-add when the fork is healthy.
|