PdfCraft: An open-source PDF reader and editor written by scratch in pure Rust
M14: Spanish catalog covers the bundled key union
Fernando Areán4ac70042924e
diff --git a/ROADMAP.md b/ROADMAP.mdindex b1283e775..b0636bb7a 100644--- a/ROADMAP.md+++ b/ROADMAP.md@@ -132,14 +132,14 @@ What's strong and missing in each: [target-app-parity.md](docs/target-app-parity## Languages-Twelve key languages (historical % snapshot vs 2,143 keys, except Vietnamese vs the current-union). Detail and script notes: [localization-parity.md](docs/localization-parity.md).+Twelve key languages (historical % snapshot vs 2,143 keys, except Vietnamese and Spanish vs the+current union). Detail and script notes: [localization-parity.md](docs/localization-parity.md).| Language | Code | Strings | Status ||---|---|---|---|| English | `en` | 100% | full || Simplified Chinese | `zh-hans` | 97.4% | partial (no Hans UI face in releases, #826) |-| Spanish | `es` | 95.5% | partial |+| Spanish | `es` | 100% of current union | partial (dialogs / tooltips; no help) || Hindi | `hi` | 0% | none || Arabic | `ar` | 100% | partial (layout not mirrored) || French | `fr` | 99.3% | partial |@@ -201,6 +201,7 @@ Ranked; detail and the full milestone table in [docs/roadmap.md](docs/roadmap.md- **2026-10-16 (M10, #1201 partial):** Lossless image export applies each component's Decode pair. Indexed values round and clip before palette lookup. Color-key masks keep raw samples. The existing 16-bit precision limit remains. JPEG and mask Decode, ICC transforms, and calibrated colors remain outside this fix. Estimates unchanged.- **2026-10-16 (M3, #2739):** Wrapped revision buttons stay above Binding in Document Properties. A synthetic regression checks control bounds and opens a saved revision at two viewport widths. Estimates unchanged.- **2026-10-19 (M7, tracked text):** Editable paragraphs and object labels distinguish repeated glyph tracking from word gaps in TJ arrays and separately positioned glyphs. Synthetic regressions cover character spacing, horizontal scaling, rotated baselines, larger word gaps, and rows of one-glyph words or cells (inferred tracking is capped at half an em, so `a b c` and digit or Y/N columns keep their spaces). Estimates unchanged.+- **2026-10-20 (M14, Spanish catalog gaps):** `es.tsv` gains the 143 `(context, English)` keys the other catalogs carried and it was missing, so Spanish covers the whole bundled key union like Lithuanian and Vietnamese: calendar months and weekdays, the `certificate` context, X.509 key usages, signature-revision and digital-ID lines, password validation, eight plural messages, the combine-from-folder strings, the rendering and stale-file notices and the shortcut-spelled tooltips. Counts in `localization-parity.md` re-measured against the current union (`vi` restated against it for the same reason). Status stays `partial`: no translated help, and OS details stay outside the catalog. Estimates unchanged.- **2026-10-15 (M2, gap 12):** `cargo xtask text-oracle` scores reading order as well as word F1: the longest common subsequence of the two word sequences over the longer one. F1 is a bag of words and cannot see order at all -- measuring #2431, a change that moves text and nothing else, it called 26 of the 29 files whose output changed identical, where the order score separated 18 improvements from 6 regressions. Reports, does not gate; a disagreement with Poppler, not a verdict. Estimates unchanged.- **2026-10-15 (M2, #2305 follow-up):** WinAnsiEncoding 0xA0 and 0xAD and MacRomanEncoding 0xCA extract as the ordinary space and hyphen Annex D.2 names them, in the vendored hayro tables (patch 30) as well as `crates/fonts`, so search, copy and redaction see characters that were hidden behind U+00A0 and U+00AD. Across the pdf.js corpus the soft hyphens we extract fall 117 to 13 and the non-breaking spaces 30 to 26; the rest come from `/ToUnicode`. An explicit `/Differences` name keeps its glyph list value, as pdftotext does. Estimates unchanged.- **2026-10-15 (M12, XFA, #2574):** A `pageArea` with no `<occur>` repeats without limit instead of taking a subform's default of one use, so a later page area with `occur max="1"` is no longer drawn (with a copy of its fields) over every body page. A page area's `occur min` is honoured too: one the body never reached gets the pages it still needs after the body (the once-only closing page of a form, with its button, comes last). Acrobat Pro also puts that page last, and when printing keeps it but leaves it blank (`relevant="-print"` on the page area), which PdfCraft does not do yet; both re-observed on a synthetic fixture, see the 2026-10-19 line. Synthetic regression tests. Estimates unchanged.diff --git a/crates/ui-egui/src/i18n/es.tsv b/crates/ui-egui/src/i18n/es.tsvindex 79c668992..be5b06eb2 100644--- a/crates/ui-egui/src/i18n/es.tsv+++ b/crates/ui-egui/src/i18n/es.tsv@@ -2574,3 +2574,176 @@ animation effects Off Desactivados# Historical snapshot notice bar (View signed version / View revision).You are viewing the signed version of “{from}” (revision {rev}). It is a snapshot: changes here won't affect the original. Estás viendo la versión firmada de «{from}» (revisión {rev}). Es una instantánea: los cambios aquí no afectarán al original.You are viewing revision {rev} of “{from}”. It is a snapshot: changes here won't affect the original. Estás viendo la revisión {rev} de «{from}». Es una instantánea: los cambios aquí no afectarán al original.++#+# Keys the other catalogs carry that this one was missing, so Spanish covers the bundled key union+# the way Lithuanian and Vietnamese do (`lithuanian_covers_bundled_catalog_keys_including_dynamic_dialog_labels`).+# Same clean-room rule as the header: written from the plain meaning of the English label, reusing+# the vocabulary already in this file (ID digital, marcador, Acercar / alejar, Portapapeles).+#+# The date picker.+calendar date January enero+calendar date February febrero+calendar date March marzo+calendar date April abril+calendar date May mayo+calendar date June junio+calendar date July julio+calendar date August agosto+calendar date September septiembre+calendar date October octubre+calendar date November noviembre+calendar date December diciembre+calendar weekday Mo Lu+calendar weekday Tu Ma+calendar weekday We Mi+calendar weekday Th Ju+calendar weekday Fr Vi+calendar weekday Sa Sá+calendar weekday Su Do+#+# Certificate details, in their own context beside the plain labels.+certificate Issued to Emitido a+certificate Issued by Emitido por+certificate Issuer Emisor+certificate Serial number Número de serie+certificate Version Versión+certificate Public key Clave pública+certificate Key usage Uso de la clave+certificate Intended usage Uso previsto+certificate Basic constraints Restricciones básicas+certificate Self-signed Autofirmado+certificate Valid from Válido desde+certificate Valid to Válido hasta+certificate Validity starts La validez empieza+certificate Validity ends La validez termina+certificate SHA-1 digest Huella SHA-1+certificate SHA-256 digest Huella SHA-256+#+# What a certificate's key may be used for (X.509 key usage), as the details list them.+ Digital Signature Firma digital+ Non-Repudiation No repudio+ Key Encipherment Cifrado de claves+ Data Encipherment Cifrado de datos+ Key Agreement Acuerdo de claves+ Certificate Signing Firma de certificados+ CRL Signing Firma de CRL+ Encipher Only Solo cifrado+ Decipher Only Solo descifrado+#+# Signatures, revisions and digital IDs.+ {who}, certificate issued by {issuer}. {who}, certificado emitido por {issuer}.+ {who}, certificate issued by an unknown issuer. {who}, certificado emitido por un emisor desconocido.+ Rev. {rev}: Signed by {name} Rev. {rev}: Firmado por {name}+ Rev. {rev}: Signed by an unknown signer Rev. {rev}: Firmado por un firmante desconocido+ Rev. {rev}: Certified by {name} Rev. {rev}: Certificado por {name}+ Rev. {rev}: Certified by an unknown signer Rev. {rev}: Certificado por un firmante desconocido+ Unsigned signature field: {name} Campo de firma sin firmar: {name}+ Choose a digital ID. Elige un ID digital.+ There is no folder to save the digital ID in. No hay ninguna carpeta donde guardar el ID digital.+#+# Passwords.+ The password is incorrect. La contraseña es incorrecta.+ The password must have at least 6 characters. La contraseña debe tener al menos 6 caracteres.+ The password must have at least 8 characters. La contraseña debe tener al menos 8 caracteres.+ The passwords do not match. Las contraseñas no coinciden.+ Only the document's owner can change its security (open it with the permissions password) Solo el propietario del documento puede cambiar su seguridad (ábrelo con la contraseña de permisos)+#+# Counts.+@plural {n} byte|{n} bytes {n} byte|{n} bytes+@plural {n} pixel|{n} pixels {n} píxel|{n} píxeles+@plural {n} file|{n} files {n} archivo|{n} archivos+@plural {n} comment|{n} comments {n} comentario|{n} comentarios+@plural {n} result|{n} results {n} resultado|{n} resultados+@plural {n} image optimized|{n} images optimized {n} imagen optimizada|{n} imágenes optimizadas+@plural {n} item discarded|{n} items discarded {n} elemento descartado|{n} elementos descartados+@plural Delete {n} field|Delete {n} fields Eliminar {n} campo|Eliminar {n} campos+#+# Combining PDFs from a folder.+ Add the PDFs to combine Añade los PDF que vas a combinar+ Drop PDFs or folders here, or choose them. Suelta aquí PDF o carpetas, o elígelos.+ Every PDF in the folder Todos los PDF de la carpeta+ Every PDF in the folder and the folders inside it Todos los PDF de la carpeta y de las carpetas que contiene+ Added the first {n} PDFs in {folder} Se han añadido los primeros {n} PDF de {folder}+ No PDFs found in {folder} No se ha encontrado ningún PDF en {folder}+#+# Panels, rendering and notices.+ Panel layout could not be restored: {error} No se ha podido restaurar la disposición de los paneles: {error}+ Panel move was not applied: {error} No se ha aplicado el movimiento del panel: {error}+ Rendering… Renderizando…+ Still rendering — this page is unusually complex… Sigue renderizando: esta página es excepcionalmente compleja…+ Loading… Cargando…+ This file changed on disk. Reload it to see the new version; your unsaved changes will be lost. Este archivo cambió en el disco. Recárgalo para ver la versión nueva; se perderán los cambios sin guardar.+ Text recognition isn't installed: its models are missing (run `cargo xtask models`, or set PDFCRAFT_MODELS). El reconocimiento de texto no está instalado: faltan sus modelos (ejecuta `cargo xtask models` o define PDFCRAFT_MODELS).+ Cut and stack needs Two-sided: Off. Print single-sided sheets. Cortar y apilar necesita «A doble cara: Desactivado». Imprime hojas a una cara.+ Error Error+ Warning Advertencia+ Information Información+ Success Correcto+#+# Asking for something, and choosing it.+ Enter a name. Introduce un nombre.+ Enter a page number Introduce un número de página+ Enter a URL Introduce una URL+ Enter the field names Introduce los nombres de los campos+ Choose… Elegir…+ Choose a file… Elegir un archivo…+ Choose a folder… Elegir una carpeta…+ Create folder Crear carpeta+ Open folder Abrir carpeta+ Save file Guardar archivo+ Save changes? ¿Guardar los cambios?+#+# Settings and their values.+ Theme Tema+theme Appearance Aspecto+ System Sistema+ English Inglés+ Always Siempre+ Never Nunca+ Automatically Automáticamente+ On Activado+ Enabled Activado+ Disabled Desactivado+ Mouse wheel scroll speed Velocidad de desplazamiento de la rueda del ratón+ Margins (in) Márgenes (pulg.)+#+# Labels and commands the catalogs name on their own.+ Color Color+ Font Fuente+ Folder Carpeta+ Comment Comentario+ Comment and review Comentar y revisar+ Creator Creador+ Producer Productor+ Organize Organizar+ Import Importar+ Move Mover+ Duplicate Duplicar+ Paste Pegar+ Select all Seleccionar todo+ Refresh Actualizar+ Next Siguiente+ Previous Anterior+ of de+ No results Sin resultados+ Search results Resultados de la búsqueda+ Copy to clipboard Copiar al portapapeles+ Copied to clipboard Copiado al portapapeles+ Help… Ayuda…+ on page {label} en la página {label}+ Page {n} Página {n}+ Page {n} of {total} Página {n} de {total}+#+# Tooltips that spell their shortcut out.+ Open a PDF (⌘O) Abrir un PDF (⌘O)+ Print (⌘P) Imprimir (⌘P)+ Document properties (⌘D) Propiedades del documento (⌘D)+ New bookmark (⌘B) Nuevo marcador (⌘B)+ Next (⌘G) Siguiente (⌘G)+ Previous (⇧⌘G) Anterior (⇧⌘G)+ Zoom in (⌘+) Acercar (⌘+)+ Zoom out (⌘−) Alejar (⌘−)+ Zoom in / out (also pinch or ⌘-scroll) Acercar / alejar (también con pellizco o ⌘ + desplazamiento)+ Rotate view clockwise (⇧⌘+) Girar la vista a la derecha (⇧⌘+)+ Save (M4) Guardar (M4)diff --git a/docs/localization-parity.md b/docs/localization-parity.mdindex 995293af3..639ce249f 100644--- a/docs/localization-parity.md+++ b/docs/localization-parity.md@@ -1,7 +1,7 @@# Localization parity> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-10-13 · **Change:** minor (Vietnamese 100% of current key union; native-speaker community review; twelve-language mean ≈68%) · **Target:** Adobe Acrobat Pro (Acrobat DC, continuous track 26.002.21931, macOS)-> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-10-14 · **Change:** minor (Italian count after completing its catalog) · **Target:** Adobe Acrobat Pro (Acrobat DC, continuous track 26.002.21931, macOS)+> **Last reviewed:** 2026-10-10 · **Last updated:** 2026-10-20 · **Change:** minor (Spanish 100% of the current key union) · **Target:** Adobe Acrobat Pro (Acrobat DC, continuous track 26.002.21931, macOS)Per-language status of PdfCraft's interface against Acrobat Pro's. How translations work and how toadd a language: [localization.md](localization.md). Summary in [ROADMAP.md](../ROADMAP.md).@@ -10,10 +10,10 @@ add a language: [localization.md](localization.md). Summary in [ROADMAP.md](../R- **Strings translated** is measured: the catalogs in `crates/ui-egui/src/i18n/<code>.tsv`, countedas distinct `(context, English)` keys with a non-empty translation. The **current** denominator is- the union of keys across all catalogs (**2,590** plain keys as of 2026-10-13, plus language-specific- context rows such as Vietnamese `theme`/`Appearance`). The twelve-language percentage table below+ the union of keys across all catalogs (**2,674** keys as of 2026-10-20, counting language-specific+ context rows such as `theme`/`Appearance`). The twelve-language percentage table belowstill quotes the **historical 2,143-key snapshot** from 2026-10-10 for every language except- Vietnamese (re-measured against the current union). English is built in.+ Vietnamese and Spanish (re-measured against the current union). English is built in.- **Not counted:** error details from the engine and the operating system, which are shown inEnglish inside a translated frame; there is no translated user documentation or help yet (Acrobatships localized help).@@ -31,7 +31,7 @@ add a language: [localization.md](localization.md). Summary in [ROADMAP.md](../R|---|---|---|---|---|---|---|---|---|| English | `en` | built in (100%) | all; README and docs | Latin | yes | **full** | yes | 0 || Simplified Chinese | `zh-hans` | 2,088 (97.4%) | dialogs and tooltips through `tl!`; no help | CJK text and IME work, but **release builds have no Hans face**: many characters show as boxes (#826, #688, #728, #758; Flatpak #689) | no | partial | yes | 6–12 |-| Spanish | `es` | 2,046 (95.5%) | dialogs and tooltips; no help | Latin | no | partial | yes | 2–4 |+| Spanish | `es` | 2,674 (100% of current key union) | dialogs and tooltips; no help | Latin | no | partial | yes | 2–4 || Hindi | `hi` | 0 | none | Devanagari not tested (egui shapes Telugu conjuncts, so shaping is likely workable); no Devanagari face in craft-fonts | no | none | no | 10–18 || Arabic | `ar` | 2,143 (100%) | dialogs and tooltips; no help | Letters joined and lines reordered at load, but **layout not mirrored**, wrapped lines break at the wrong end, typed text runs left to right (`localization.md` §Arabic) | no | partial | yes (Middle East edition) | 25–45 || French | `fr` | 2,128 (99.3%) | dialogs and tooltips; no help | Latin | no | partial | yes | 1–2 |@@ -40,7 +40,7 @@ add a language: [localization.md](localization.md). Summary in [ROADMAP.md](../R| Japanese | `ja` | 2,123 (99.1%) | dialogs and tooltips; no help | BIZ UDPGothic from craft-fonts; IME patched on macOS, Windows, X11, Wayland; vertical text renders but can't be edited | no | partial | yes | 4–8 || German | `de` | 2,128 (99.3%) | dialogs and tooltips; no help | Latin | community, in progress (#828: terminology, clipping) | partial | yes | 2–4 || Korean | `ko` | 0 | none | Hangul IME patched (Microsoft and Apple Korean, `vendor/README.md` winit 3, 6, 9, 10); no Hangul UI face in craft-fonts | no | none | yes | 6–10 |-| Vietnamese | `vi` | 2,591 (100% of current union + theme Appearance) | dialogs and tooltips; no help | Latin with stacked diacritics; bundled Inter covers them (fonts test) | community | partial | no | 2–4 |+| Vietnamese | `vi` | 2,674 (100% of current key union) | dialogs and tooltips; no help | Latin with stacked diacritics; bundled Inter covers them (fonts test) | community | partial | no | 2–4 |**Localization dimension ≈ 68%**: the mean over the twelve, counting a catalog's percentage but only60% for Chinese and Arabic until their script problems are fixed, and 0 for Hindi, Indonesian and@@ -49,8 +49,8 @@ to bring all twelve to `full`, of which ≈ 35–60 h is engineering (Hans face,and the rest catalogs and fixes; native-speaker review needs humans.No language is `full` except English: every catalog leaves engine error details in English, and-none has translated help. Vietnamese's **To `full`** hours are therefore residual help/docs polish-(catalog and script work are already done), not missing UI strings.+none has translated help. The **To `full`** hours of Vietnamese and Spanish are therefore residual+help/docs polish (catalog and script work are already done), not missing UI strings.## Other shipped languages@@ -82,6 +82,7 @@ Acrobat languages PdfCraft lacks: Danish, Dutch, Finnish, Norwegian, Swedish, He| Date | Change | Summary ||---|---|---|+| 2026-10-20 | minor | Spanish: the 143 keys the other catalogs had and `es.tsv` was missing; `es` now covers the whole 2,674-key union, like `lt` and `vi` || 2026-10-13 | minor | Vietnamese (`vi`) catalog: 2,591 entries (100% of current key union + `theme`/`Appearance`); twelve-language mean ≈ 68%; native-speaker community review; registered with `plural_none` || 2026-10-14 | minor | Italian: 2,528 entries after adding the 201 keys the other catalogs had and the code looks up || 2026-10-12 | minor | Added current counts for Kazakh, Polish, Slovenian, Greek, Turkish and Lithuanian; retained existing language assessments and the original percentage snapshot |