Skip to content

Languages

RustGIS's interface is available in 20 languages:

Language Code Language Code
English en Русский (Russian) ru
Deutsch (German) de Türkçe (Turkish) tr
Español (Spanish) es Azərbaycanca (Azerbaijani) az
Français (French) fr Bahasa Indonesia (Indonesian) id
Italiano (Italian) it Tiếng Việt (Vietnamese) vi
Nederlands (Dutch) nl 简体中文 (Chinese, Simplified) zh
Polski (Polish) pl 日本語 (Japanese) ja
Português (Portuguese) pt 한국어 (Korean) ko
ქართული (Georgian) ka বাংলা (Bengali) bn
فارسی (Persian) fa Ελληνικά (Greek) el

Choosing a language

By default RustGIS follows the first supported language in your system's preferences (your browser's on the web) and falls back to English. The Chinese catalog is Simplified Chinese; Traditional Chinese locales are not mapped to it. To choose a language yourself, open Settings › Language. The choice is remembered in prefs.json in the desktop app's settings folder, or in browser storage on the web. When following the system language, you can override its detection for one desktop run with RUSTGIS_LANGUAGE:

RUSTGIS_LANGUAGE=de cargo run --release -p rustgis

Only the interface is translated. Your data, layer and field names, command ids and the command line stay as they are, so scripts work in every language.

Chinese, Japanese and Korean need a CJK font. The desktop app uses one you have installed (Noto Sans CJK, Microsoft YaHei, Yu Gothic, Malgun Gothic, PingFang, Hiragino or Apple SD Gothic Neo); the web app downloads Noto Sans from assets.rustgis.app the first time you pick one of these languages. Map labels in images exported from the desktop app and the command line draw CJK text with the same installed font, whatever the interface language. Images exported from the web app have no CJK font yet, so CJK characters are left out of their labels.

Persian needs a font with both Arabic-script and Latin letters. The desktop app uses one you have installed (Segoe UI, Tahoma, Arial, Vazirmatn or DejaVu Sans); the web app downloads Vazirmatn from assets.rustgis.app the first time you pick Persian.

Translating

Each non-English language is a UTF-8 catalog of English<TAB>Translation lines in crates/ui-egui/src/i18n/<code>.tsv. English is the source language and has no catalog. Blank lines and lines beginning with # are ignored. Within either field, \n, \t and \\ represent a line break, tab and backslash. A missing entry shows in English, so translations can grow one line at a time, and corrections from native speakers are welcome.

Pull requests can leave new strings out of the catalogs: the maintainer translates them before each release. To translate a new string, add a line with the exact English text, a tab, and the translation. Keep {placeholders} such as {n} or {name} (they may move), keep the line break (\n) in two-line ribbon labels, and leave product, format and key names (RustGIS, GeoJSON, CSV, Ctrl…) in English. To add a language, add its catalog and a row in LANGUAGES in crates/ui-egui/src/i18n/mod.rs. The i18n tests check catalog format and placeholders, and require translations for some established interface strings:

cargo test -p rustgis-ui-egui i18n

Context for ambiguous words

Existing two-column catalogs keep their meaning. For a word used in different senses, an optional first column gives a stable context: Context<TAB>English<TAB>Translation. An empty context is the same as an ordinary two-column row. For example, a German catalog can contain:

Open    Öffnen
file-state  Open    Offen

Use tl!("Open", context = "file-state") at the call site. tl_raw! accepts the same context for fragments, and i18n::fmt_context("file-state", "{n} open", &[("n", count)]) formats a contextual message. Contexts describe the sense of a word, not a translated label. When a contextual entry is missing, lookup falls back to the ordinary translation, then to English. Plugin catalogs keep their existing format and provide the ordinary fallback.

Each context and English key may appear only once, including after unescaping. The catalog tests check contextual placeholders too; malformed and duplicate rows report their line number.

Persian text uses the toolkit's script shaping, with Latin runs and brackets adjusted by crates/ui-egui/src/i18n/rtl.rs. Long paragraphs are broken into lines before drawing. Panes and widgets retain their left-to-right layout. Arabic, Hebrew, Hindi and Thai are not included in the language picker.