Files
wordcraft/docs/localization-sv.md
T
3cbea099f1 i18n: add Swedish (sv) interface translation (#1219)
* i18n: add Swedish (sv) interface translation

A 2,504-entry Swedish catalog: every key of the reference catalog, the equation gallery's
labels, everything the interface audit finds, and 44 newer strings no catalog had yet (the
native print settings among them). Written from the meaning of the English labels in ordinary
Swedish computing vocabulary; no other product's localisation and no other catalog was used.
An AI-assisted draft whose terminology and running app were reviewed by a native speaker.
Counts use count-neutral wording ("21 ord").

- sv, sv-SE, sv_SE.UTF-8 and sv-FI select it automatically; "Svenska" in Options and
  ui.language with {"value":"sv"}.
- The interface audit checks Swedish the way it checks Russian, Hungarian, Turkish and
  Bulgarian.
- Tests: locales and saved preference, catalog coverage and key translations, the search
  hint's example, count wording, and the bundled Inter/JetBrains Mono faces covering å ä ö é.
- native_print: the narrow-window test pins English, since it finds controls by their English
  labels (it failed on a Swedish machine once those labels had a translation).
- The Hungarian locale test used sv-SE as an unsupported language; it now uses fi-FI.
- ATTRIBUTION, README, ROADMAP, docs/localization-parity.md and a new
  docs/localization-sv.md; a contributors/people.toml entry for @holmbom.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* Swedish rows for the cross-reference dialog

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
Co-authored-by: Brandon Thomas <echelon@gmail.com>
2026-10-15 00:03:13 -04:00

98 lines
5.9 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# Swedish interface
> **Last reviewed:** 2026-10-13 · **Last updated:** 2026-10-13 · **Change:** minor (Swedish interface catalog and regression checks) · **Target:** WordCraft 0.6.1
Choose **File › Options › Interface language › Svenska**, or follow a Swedish system display
language (`sv-SE`, `sv_SE.UTF-8`, and `sv-FI` for Swedish in Finland). The catalog code is `sv`;
`ui.language` with `{"value":"sv"}` selects it explicitly, and `WORDCRAFT_LANGUAGE=sv-SE` does the
same for a headless screenshot or a launch while the preference is `auto`. The choice is saved with
the other interface settings. Document text, command ids, CLI/MCP/control responses and file paths
do not change.
`crates/ui-egui/src/i18n/sv.tsv` has 2,504 entries: every key of the Spanish reference catalog and
of the Bulgarian one (built-in style names, equation gallery labels, paper sizes, watermarks and
citation styles included), plus 44 newer strings no other catalog has yet: 23 that the interface
audit finds and 21 that the code sends through translation outside the audit's reach (native print
settings, Go To, command search). It is written from the meaning of the English labels; no other
product's Swedish interface, string table or terminology database was consulted, and no other
catalog was used as a source. The catalog format has no plural forms, and Swedish counts don't need
them: `ord` (word) is the same in the singular and the plural (`1 ord`, `21 ord`). Placeholders,
`\n` breaks in ribbon labels and dialog ellipses are kept, and strings added later fall back to
English until they are translated.
The draft was made with Claude Code. A native speaker approved the terminology and every open
wording choice, and reviewed the running app.
## Conventions
- Commands are imperatives (`Spara`, `Infoga tabell`); messages address the user as `du`. When two
words are equally right, the softer everyday one wins (`Använd`, not `Verkställ`).
- Ribbon tabs keep the English word class: `Infoga`, `Rita`, `Granska` and `Visa` are verbs because
the same keys are also buttons and groups. Other tabs and groups are nouns.
- Only the first word of a label is capitalised (`Acceptera alla ändringar`).
- `Markera` means select and `Välj` means choose from a list. Mark, markup and highlight use other
words (`Märk post`, `märkning`, `Framhäv`, `Överstrykning`), so the two never mix.
- Ribbon buttons with a `\n` break are separate keys from the command names and may be shorter
where the group gives the context: the button `Framhäv\nfält`, the command `Framhäv kopplingsfält`.
- Decimal comma in fixed labels (`Radavstånd 1,5`, `8,5" × 11"`), Swedish quotation marks (”…”),
and a spaced en dash where English has an em dash (`Redigering – redigera dokumentet direkt`).
- Names stay as they are: WordCraft, Zotero, SmartArt, WordArt, the Craft theme, paper sizes
(Letter, Legal …) and citation styles (APA, MLA …). Loanwords Swedish speakers use stay too:
`community`, `commit`.
## Terminology
| Source | Swedish |
|---|---|
| File / Home / Insert / Draw / Design / Layout | Arkiv / Start / Infoga / Rita / Design / Layout |
| References / Mailings / Review / View / Help | Referenser / Utskick / Granska / Visa / Hjälp |
| Ribbon / Pane / Quick Access Toolbar | Verktygspanel / Panel / Snabbverktygsfält |
| Font / Font Size / Font Color | Typsnitt / Teckenstorlek / Teckenfärg |
| Paragraph / Style / Styles | Stycke / Stil / Stilar |
| Select / Selection / Choose | Markera / Markering / Välj |
| Highlight / Markup / Mark Entry | Överstrykning / Märkning / Märk post |
| Picture / Shape / Caption | Bild / Figur / Bildtext |
| Header / Footer / Heading | Sidhuvud / Sidfot / Rubrik |
| Footnote / Endnote / Notes | Fotnot / Slutnot / Fot- och slutnoter |
| Table of Contents / Index / Bibliography | Innehållsförteckning / Register / Källförteckning |
| Track Changes / Accept / Reject | Spåra ändringar / Acceptera / Avvisa |
| Mail Merge / Recipients / Merge Field | Dokumentkoppling / Mottagare / Kopplingsfält |
| Columns (text and table) | Kolumner |
| Options / Apply | Alternativ / Använd |
| Page {page} of {pages} / {words} words | Sida {page} av {pages} / {words} ord |
## Known compromises
The catalog has one translation per English key, so a key used in two senses gets the wording that
fits its most visible place:
- `Outline` is both the View tab's Outline view and the Font menu's text outline effect:
`Disposition`, which is wrong for the text effect.
- `Display` is both an Options page and the Equation tab's display-equation button: `Visning`; the
button's tooltip explains it.
- `Open` is File › Open and a paragraph-spacing preset: `Öppna`.
Giving these call sites a translation context (`tc`) would fix them. Some AutoCorrect options
describe English typing (`Capitalize names of days`, `Ordinals (1st) as superscript`, smart
quotes); they are translated as written and still act on English text.
## Verification and remaining scope
`cargo test -p wordcraft-ui-egui --lib i18n::tests` covers Swedish locale tags (`sv`, `sv-SE`,
`sv_SE.UTF-8`, `SV-se`, `sv-FI`) and preference order, saving and restoring `sv`, unchanged
document content, every key of the reference catalog, no catalog errors, the search hint's example
(`infoga tabell`), page and count wording, English fallback, and the glyphs `ÅÄÖåäöÉé` plus every
other accented letter the catalog uses in the bundled Inter (Regular, Medium, SemiBold) and
JetBrains Mono. The shared catalog checks (validation, every tab and command translated) include
Swedish automatically, and the on-demand interface audit (`untranslated_interface_text`) checks
Swedish alongside Russian, Hungarian, Turkish and Bulgarian.
Spelling, grammar and hyphenation stay English-only: this is an interface translation, not
Swedish proofing.
## Revision history
| Date | Change | Summary |
|---|---|---|
| 2026-10-13 | minor | Swedish catalog (2,504 entries), conventions, terminology, known compromises and regression checks |