Skip to content

i18n: add French (fr) interface - #413

Merged
h-a-n-a-s-h-i merged 1 commit into
storytold:mainfrom
pechnikov2026-star:i18n-fr
Oct 11, 2026
Merged

h-a-n-a-s-h-i merged 1 commit into
storytold:mainfrom
pechnikov2026-star:i18n-fr

Conversation

@pechnikov2026-star

Copy link
Copy Markdown

Summary

Adds a complete French interface catalog for GridCraft: 379 entries covering every JAPANESE key (the coverage reference in the uniqueness test). French-only, following the maintainer's guidance from #366.

Changes

  • crates/ui-egui/src/i18n/fr.rs — new translate() module (379 entries)
  • crates/ui-egui/src/i18n.rs — mod fr;, Language::Fr variant (ALL 9 → 10, name, code, tag parsing, tr() arm), uniqueness/coverage test extended to French, locale tags fr-FR/fr_CA resolve

Translation notes

  • Clean-room wording: translations written from the meaning of the English source, not copied from Excel's localized French strings
  • Excel fr-FR terminology: Feuille, Classeur, Formule, Cellule, Plage, Figer les volets, Filtrer, Trier, Graphique
  • The two Context|Label keys carry plain labels as values; multi-line \n keys (e.g. Top\nAlign) verified to resolve identically to the JAPANESE reference
  • Format/function names stay Latin: CSV, PDF, A1/R1C1, SUM etc.

Testing

  • cargo test -p gridcraft-ui-egui --lib: 62 passed, 0 failed (the translations_are_unique_and_preserve_unknown_text test asserts French translates every JAPANESE key)

A complete 379-entry catalog covering every JAPANESE key (the coverage
reference), registered as a Fr variant in the Language enum. The
uniqueness/coverage test now asserts French alongside the other
languages; locale tags fr-FR and fr_CA resolve.
@h-a-n-a-s-h-i
h-a-n-a-s-h-i merged commit 63e60de into storytold:main Oct 11, 2026
@echelon

echelon commented Oct 11, 2026

Copy link
Copy Markdown
Member

Merged — thank you for the contribution! If you haven't already, please join our Discord: https://discord.gg/artcraft

@Dejan-Port

Copy link
Copy Markdown
Contributor

Heads up — while fixing a CI failure on another PR (a missing key, `translations_are_unique_and_preserve_unknown_text`), I found this went further than just that one key: around 50 other keys in `fr.rs` were present but mapped to the wrong value — the French translation of a different, unrelated English string, not their own. The completeness test only checks that a value exists and is non-empty, so it never caught this.

A few examples (key → what it was showing → what that text actually means):

Key Was mapped to Which actually means
`"Click to add data"` `"Fermer"` Close
`"Header"` `"Informations"` Info
`"Ruler"` `"Enregistrer sous"` Save As
`"Info"` `"Insérer les cellules copiées…"` Insert Copied Cells…
`"Animations"` `"Auteur"` Author

Not a local swap between neighbors — some of these drew values from entries far apart in the file, so I couldn't safely patch individual lines without risking missing more. I regenerated all 381 entries from the English source text and opened #454 with the full diff and reasoning. Tagging you since you'd know best whether something specific in the original authoring process caused this (tooling, a bad merge, etc.) — happy to adjust #454 if you'd rather review/redo it a different way.

neilcawse added a commit to neilcawse/gridcraft that referenced this pull request Oct 12, 2026
…/footer labels

CSV/TSV export ran General numbers through the 11-character cell display, so a
barcode like 124412140710 was saved as 1.24412E+11. display::value_text now
writes a General number as & converts it (number_to_text), as its doc already
said; cell_text keeps the cell display. Fixes the two storytold#426 tests that broke when
storytold#422 merged.

Adds the French "Different First Page" / "Different Odd & Even Pages" labels
missing after storytold#413, which failed the i18n completeness test.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
marcoarnulfo pushed a commit to marcoarnulfo/gridcraft that referenced this pull request Oct 15, 2026
…/footer labels

CSV/TSV export ran General numbers through the 11-character cell display, so a
barcode like 124412140710 was saved as 1.24412E+11. display::value_text now
writes a General number as & converts it (number_to_text), as its doc already
said; cell_text keeps the cell display. Fixes the two storytold#426 tests that broke when

Adds the French "Different First Page" / "Different Odd & Even Pages" labels
missing after storytold#413, which failed the i18n completeness test.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
dabaicai001 added a commit to dabaicai001/gridcraft that referenced this pull request Oct 16, 2026
storytold#404's header/footer variants landed after storytold#413's French table, leaving the
translation-completeness test red.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants