Add new translation key "Aspect Ratio"

This commit is contained in:
Henrik Rydgård 2022-11-27 19:42:30 +01:00
parent a0f10141ab
commit dbd799bce3
43 changed files with 90 additions and 4 deletions

View File

@ -18,6 +18,10 @@ enum Command {
CopyMissingLines {},
CommentUnknownLines {},
RemoveUnknownLines {},
AddNewKey {
section: String,
key: String,
},
MoveKey {
old: String,
new: String,
@ -89,6 +93,15 @@ fn remove_key(target_ini: &mut IniFile, section: &str, key: &str) -> io::Result<
Ok(())
}
fn add_new_key(target_ini: &mut IniFile, section: &str, key: &str) -> io::Result<()> {
if let Some(section) = target_ini.get_section_mut(section) {
let _ = section.insert_line_if_missing(&format!("{} = {}", key, key));
} else {
println!("No section {}", section);
}
Ok(())
}
fn main() {
let opt = Opt::from_args();
@ -97,15 +110,15 @@ fn main() {
let mut filenames = args;
let root = "../../assets/lang";
let reference_file = "en_US.ini";
let reference_ini_filename = "en_US.ini";
let reference_ini = IniFile::parse(&format!("{}/{}", root, reference_file)).unwrap();
let mut reference_ini = IniFile::parse(&format!("{}/{}", root, reference_ini_filename)).unwrap();
if filenames.is_empty() {
// Grab them all.
for path in std::fs::read_dir(root).unwrap() {
let path = path.unwrap();
if path.file_name() == reference_file {
if path.file_name() == reference_ini_filename {
continue;
}
let filename = path.file_name();
@ -118,6 +131,7 @@ fn main() {
}
for filename in filenames {
let reference_ini = &reference_ini;
if filename == "langtool" {
// Get this from cargo run for some reason.
continue;
@ -137,12 +151,16 @@ fn main() {
Command::RemoveUnknownLines {} => {
deal_with_unknown_lines(&reference_ini, &mut target_ini, true).unwrap();
}
Command::AddNewKey {
ref section,
ref key,
} => add_new_key(&mut target_ini, section, key).unwrap(),
Command::MoveKey {
ref old,
ref new,
ref key,
} => {
move_key(&mut target_ini, &old, &new, &key).unwrap();
move_key(&mut target_ini, old, new, key).unwrap();
}
Command::RemoveKey {
ref section,
@ -155,5 +173,31 @@ fn main() {
target_ini.write().unwrap();
}
println!("Langtool processing {}", reference_ini_filename);
// Some commands also apply to the reference ini.
match opt.cmd {
Command::AddNewKey {
ref section,
ref key,
} => {
add_new_key(&mut reference_ini, section, key).unwrap();
}
Command::MoveKey {
ref old,
ref new,
ref key,
} => {
move_key(&mut reference_ini, old, new, key).unwrap();
}
Command::RemoveKey {
ref section,
ref key,
} => {
remove_key(&mut reference_ini, section, key).unwrap();
}
_ => {}
}
// println!("{:#?}", target_ini);
}

View File

@ -464,6 +464,7 @@ Aggressive = ‎عنيف
Alternative Speed = سرعة ثانوية (في %, 0 = ‎غير محدود)
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = ‎فلتر الحواف
Aspect Ratio = Aspect Ratio
Auto = ‎تلقائي
Auto (1:1) = ‎تلقائي (1:1)
Auto (same as Rendering) = ‎تلقائي (مثل حجم التصيير)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressive
Alternative Speed = Alternative speed (in %, 0 = unlimited)
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anisotropic filtering
Aspect Ratio = Aspect Ratio
Auto = Auto
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (same as rendering resolution)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressive
Alternative Speed = Алтернативна скорост
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anisotropic филтриране
Aspect Ratio = Aspect Ratio
Auto = Автоматично
Auto (1:1) = Автоматично (1:1)
Auto (same as Rendering) = Auto (same as rendering resolution)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressive
Alternative Speed = Alternative speed (in %, 0 = unlimited)
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Filtrat anisotròpic
Aspect Ratio = Aspect Ratio
Auto = Auto
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (same as rendering resolution)

View File

@ -456,6 +456,7 @@ Aggressive = Agresivní
Alternative Speed = Alternativní rychlost (v %, 0 = neomezeno)
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anizotropní filtrování
Aspect Ratio = Aspect Ratio
Auto = Automaticky
Auto (1:1) = Automatické (1:1)
Auto (same as Rendering) = Automaticky (stejné jako rozlišení vykreslování)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressiv
Alternative Speed = Alternativ hastighed (i %, 0 = ubegrænset)
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anisotropisk filtrering
Aspect Ratio = Aspect Ratio
Auto = Automatisk
Auto (1:1) = Automatisk (1:1)
Auto (same as Rendering) = Automatisk (Samme som renderingsopløsning)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressiv
Alternative Speed = Alternative Geschwindigkeit
Alternative Speed 2 = Alternative Geschwindigkeit 2 (in %, 0 = unlimitiert)
Anisotropic Filtering = Anisotropischer Filter
Aspect Ratio = Aspect Ratio
Auto = Automatisch
Auto (1:1) = Automatisch (1:1)
Auto (same as Rendering) = Automatisch (Renderauflösung)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressive
Alternative Speed = Lassi to leko'napa
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Panyaring Anisotropic
Aspect Ratio = Aspect Ratio
Auto = Ia mesa
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (same as rendering resolution)

View File

@ -456,6 +456,7 @@ Aggressive = Agresivo
Alternative Speed = Velocidad alternativa (%, 0 = ilimitada)
Alternative Speed 2 = Velocidad alternativa 2 (%, 0 = ilimitada)
Anisotropic Filtering = Filtrado anisotrópico
Aspect Ratio = Aspect Ratio
Auto = Automático
Auto (1:1) = Automático (1:1)
Auto (same as Rendering) = Automático (igual a la de renderizado)

View File

@ -456,6 +456,7 @@ Aggressive = Agresivo
Alternative Speed = Velocidad alternativa (en %, 0 = ilimitada)
Alternative Speed 2 = Velocidad alternativa 2 (en %, 0 = ilimitada)
Anisotropic Filtering = Filtrado Anisotrópico
Aspect Ratio = Aspect Ratio
Auto = Automático
Auto (1:1) = Automático (1:1)
Auto (same as Rendering) = Automático (igual a la de renderizado)

View File

@ -456,6 +456,7 @@ Aggressive = ‎شدید
Alternative Speed = ‎سرعت ثانویه
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anisotropic فیلتر
Aspect Ratio = Aspect Ratio
Auto = ‎اتوماتیک
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = ‎خودکار (مانند رزولوشن رندرینگ)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressive
Alternative Speed = Vaihtoehtoinen nopeus
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anisotrooppisen suodatus
Aspect Ratio = Aspect Ratio
Auto = Auto
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (same as rendering resolution)

View File

@ -456,6 +456,7 @@ Aggressive = Agressif
Alternative Speed = Vitesse alternative 1 (en %, 0 = illimitée)
Alternative Speed 2 = Vitesse alternative 2 (en %, 0 = illimitée)
Anisotropic Filtering = Filtrage anisotrope
Aspect Ratio = Aspect Ratio
Auto = Automatique
Auto (1:1) = Automatique (1:1)
Auto (same as Rendering) = Automatique (comme la définition du rendu)

View File

@ -456,6 +456,7 @@ Aggressive = Agresivo
Alternative Speed = Velocidade alternativa (%, 0 = ilimitada)
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Filtrado anisotrópico
Aspect Ratio = Aspect Ratio
Auto = Automático
Auto (1:1) = Automático (1:1)
Auto (same as Rendering) = Automático (igual á de renderizado)

View File

@ -456,6 +456,7 @@ Aggressive = Εξαναγκαστική
Alternative Speed = Εναλακτική προβολή ταχύτητας (στα %, 0 = απεριόριστη)
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Ανισοτροπικό Φιλτράρισμα
Aspect Ratio = Aspect Ratio
Auto = Αυτόματο
Auto (1:1) = Αυτόματο (1:1)
Auto (same as Rendering) = Αυτόματο (ίσο με την Ανάλυση Απεικόνισης)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressive
Alternative Speed = הגבלת מהירות
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anisotropic filtering
Aspect Ratio = Aspect Ratio
Auto = אוטומטי
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (same as rendering resolution)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressive
Alternative Speed = תוריהמ תלבגה
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anisotropic filtering
Aspect Ratio = Aspect Ratio
Auto = יטמוטוא
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (same as rendering resolution)

View File

@ -456,6 +456,7 @@ Aggressive = Agresivno
Alternative Speed = Alternativna brzina (u %, 0 = unlimited)
Alternative Speed 2 = Alternativna brzina 2 (u %, 0 = unlimited)
Anisotropic Filtering = Anizotropno filtriranje
Aspect Ratio = Aspect Ratio
Auto = Auto
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (isto kao Prikazna rezolucija)

View File

@ -456,6 +456,7 @@ Aggressive = Agresszív
Alternative Speed = Alternatív sebesség
Alternative Speed 2 = Alternatív sebesség 2 (%-ban, 0 = korlátlan)
Anisotropic Filtering = Anizotropikus szűrés
Aspect Ratio = Aspect Ratio
Auto = Auto
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (renderelési felbontással megegyező)

View File

@ -456,6 +456,7 @@ Aggressive = Agresif
Alternative Speed = Kecepatan alternatif (dalam %, 0 = tak terbatas)
Alternative Speed 2 = Kecepatan alternatif 2 (dalam %, 0 = tak terbatas)
Anisotropic Filtering = Pemfilteran anisotropik
Aspect Ratio = Aspect Ratio
Auto = Otomatis
Auto (1:1) = Otomatis (1:1)
Auto (same as Rendering) = Otomatis (sama dengan resolusi pelukis)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressivo
Alternative Speed = Velocità Alternativa (in %, 0 = illimitata)
Alternative Speed 2 = Velocità Alternativa 2 (in %, 0 = illimitata)
Anisotropic Filtering = Filtro Anisotropico
Aspect Ratio = Aspect Ratio
Auto = Automatico
Auto (1:1) = Automatico (1:1)
Auto (same as Rendering) = Automatico (stessa risoluzione del rendering)

View File

@ -456,6 +456,7 @@ Aggressive = 最大限
Alternative Speed = カスタム速度1 (%で指定、0 = 無制限)
Alternative Speed 2 = カスタム速度2 (%で指定、0 = 無制限)
Anisotropic Filtering = 異方性フィルタリング
Aspect Ratio = Aspect Ratio
Auto = 自動
Auto (1:1) = 自動 (1:1)
Auto (same as Rendering) = 自動 (レンダリング解像度と同じ)

View File

@ -456,6 +456,7 @@ Aggressive = Agresif
Alternative Speed = Kacepetan Alternatif
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Penyaring Anisotropis
Aspect Ratio = Aspect Ratio
Auto = Otomatis
Auto (1:1) = Otomatis (1:1)
Auto (same as Rendering) = Otomatis (padha Rendering)

View File

@ -456,6 +456,7 @@ Aggressive = 과격
Alternative Speed = 대체 속도 (%, 0 = 무제한)
Alternative Speed 2 = 대체 속도 2 (%, 0 = 무제한)
Anisotropic Filtering = 비등방성 필터링
Aspect Ratio = Aspect Ratio
Auto = 자동
Auto (1:1) = 자동 (1:1)
Auto (same as Rendering) = 자동 (렌더링 해상도와 동일)

View File

@ -456,6 +456,7 @@ Aggressive = ຮຸນແຮງ
Alternative Speed = ຄວາມໄວເສີມ (ໃນ %, 0 = ບໍ່ຈຳກັດ)
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = ກຳຈັດຄວາມບໍ່ຄົມຊັດ
Aspect Ratio = Aspect Ratio
Auto = ອັດຕະໂນມັດ
Auto (1:1) = ອັດຕະໂນມັດ (1:1)
Auto (same as Rendering) = ອັດຕະໂນມັດ (ແບບດຽວກັບຄວາມລະອຽດການສະແດງຜົນ)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressive
Alternative Speed = Alternatyvus greitis (procentais, 0 procentų = neribotas)
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = "Anisotropic" filtravimas
Aspect Ratio = Aspect Ratio
Auto = Automatinis
Auto (1:1) = Automatinė (1:1)
Auto (same as Rendering) = Automatinis (kaip Rodymo rezoliucija)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressive
Alternative Speed = Kelajuan alternatif
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anisotropic filtering
Aspect Ratio = Aspect Ratio
Auto = Auto
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (same as rendering resolution)

View File

@ -456,6 +456,7 @@ Aggressive = Agressief
Alternative Speed = Alternatieve snelheid (in %, 0 = onbeperkt)
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anisotropische filter
Aspect Ratio = Aspect Ratio
Auto = Automatisch
Auto (1:1) = Automatisch (1:1)
Auto (same as Rendering) = Auto (renderresolutie)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressive
Alternative Speed = Alternativ hastighet
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anisotropisk filtrering
Aspect Ratio = Aspect Ratio
Auto = Auto
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (same as rendering resolution)

View File

@ -456,6 +456,7 @@ Aggressive = Agresywne
Alternative Speed = Alternatywna prędkość (w %, 0 = bez limitu)
Alternative Speed 2 = Alternatywna prędkość 2 (w %, 0 = bez limitu)
Anisotropic Filtering = Filtrowanie anizotropowe
Aspect Ratio = Aspect Ratio
Auto = Automatyczne
Auto (1:1) = Automatyczna (1:1)
Auto (same as Rendering) = Auto (jak roz. renderowania)

View File

@ -480,6 +480,7 @@ Aggressive = Agressivo
Alternative Speed = Velocidade alternativa (em %, 0 = ilimitada)
Alternative Speed 2 = Velocidade alternativa 2 (em %, 0 = ilimitada)
Anisotropic Filtering = Filtragem anisotrópica
Aspect Ratio = Aspect Ratio
Auto = Auto
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (a mesma que a da resolução de renderização)

View File

@ -480,6 +480,7 @@ Aggressive = Agressivo
Alternative Speed = Velocidade alternativa (em %, 0 = ilimitada)
Alternative Speed 2 = Segunda Velocidade alternativa (em %, 0 = ilimitada)
Anisotropic Filtering = Filtragem anisotrópica
Aspect Ratio = Aspect Ratio
Auto = Automático
Auto (1:1) = Automático (1:1)
Auto (same as Rendering) = Auto (a mesma de que a da resolução de renderização)

View File

@ -456,6 +456,7 @@ Aggressive = Agresiv
Alternative Speed = Viteză alternativă (în %, 0 = nelimitat)
Alternative Speed 2 = Alternative speed 2 (in %, 0 = unlimited)
Anisotropic Filtering = Filtru Anisotropic
Aspect Ratio = Aspect Ratio
Auto = Automat
Auto (1:1) = Automat (1:1)
Auto (same as Rendering) = Automat (la fel ca rezoluția de afișare)

View File

@ -456,6 +456,7 @@ Aggressive = Принудительно
Alternative Speed = Другая скорость (в %, 0 = без ограничений)
Alternative Speed 2 = Другая скорость 2 (в %, 0 = без ограничений)
Anisotropic Filtering = Анизотропная фильтрация
Aspect Ratio = Aspect Ratio
Auto = Авто
Auto (1:1) = Авто (1:1)
Auto (same as Rendering) = Авто (как разрешение рендеринга)

View File

@ -456,6 +456,7 @@ Aggressive = Aggressiv
Alternative Speed = Alternativ hastighet
Alternative Speed 2 = Alternativ hastighet 2 (%, 0 = obegränsad)
Anisotropic Filtering = Anisotropisk filtrering
Aspect Ratio = Sidförhållande
Auto = Auto
Auto (1:1) = Auto (1:1)
Auto (same as Rendering) = Auto (samma som rendering)

View File

@ -456,6 +456,7 @@ Aggressive = Agresibo
Alternative Speed = Alternatibong bilis
Alternative Speed 2 = Alternatibong bilis 2 (in %, 0 = unlimited)
Anisotropic Filtering = Anisotropikong Pagsala
Aspect Ratio = Aspect Ratio
Auto = Awto
Auto (1:1) = Awto (1:1)
Auto (same as Rendering) = Awto (Kapareho sa Renderig Resolution)

View File

@ -456,6 +456,7 @@ Aggressive = รุนแรง
Alternative Speed = เพิ่ม-ลดระดับความเร็ว (ใน %, 0 = ไม่จำกัด)
Alternative Speed 2 = เพิ่ม-ลดระดับความเร็ว 2 (ใน %, 0 = ไม่จำกัด)
Anisotropic Filtering = ตัวกรองขจัดความไม่คมชัดของพื้นผิว
Aspect Ratio = Aspect Ratio
Auto = อัตโนมัติ
Auto (1:1) = อัตโนมัติ (1:1)
Auto (same as Rendering) = อัตโนมัติ (ค่าเดียวกับที่ใช้แสดงผลภาพ)

View File

@ -458,6 +458,7 @@ Aggressive = Agresif
Alternative Speed = Alternatif Hız (% 0 = sınırsız)
Alternative Speed 2 = Alternatif Hız 2 (% 0 = sınırsız)
Anisotropic Filtering = Anizotropik filtreleme
Aspect Ratio = Aspect Ratio
Auto = Otomatik
Auto (1:1) = Otomatik (1:1)
Auto (same as Rendering) = Otomatik (İşleme Çözünürlüğüyle Aynı)

View File

@ -456,6 +456,7 @@ Aggressive = Примусово
Alternative Speed = Альтернативна шв. (к %, 0 = необмежено)
Alternative Speed 2 = Альтернативна шв. 2 (к %, 0 = необмежено)
Anisotropic Filtering = Анізотропна фільтрація
Aspect Ratio = Aspect Ratio
Auto = Авто
Auto (1:1) = Авто (1:1)
Auto (same as Rendering) = Авто (таке ж як розширення рендерингу)

View File

@ -456,6 +456,7 @@ Aggressive = Xâm lược
Alternative Speed = Tốc độ luân phiên
Alternative Speed 2 = Tốc độ luân phiên 2 (trong %, 0 = không giới hạn)
Anisotropic Filtering = Lọc không cùng hướng
Aspect Ratio = Aspect Ratio
Auto = Tự động
Auto (1:1) = Tự động (1:1)
Auto (same as Rendering) = Tự động (cùng với kết xuất)

View File

@ -456,6 +456,7 @@ Aggressive = 激进
Alternative Speed = 自定义速度
Alternative Speed 2 = 自定义速度2
Anisotropic Filtering = 各向异性过滤
Aspect Ratio = Aspect Ratio
Auto = 自动
Auto (1:1) = 自动(1:1)
Auto (same as Rendering) = 自动(同渲染分辨率)

View File

@ -456,6 +456,7 @@ Aggressive = 積極
Alternative Speed = 替代速度 (於 %0 = 無限制)
Alternative Speed 2 = 替代速度 2 (於 %0 = 無限制)
Anisotropic Filtering = 非等向性過濾
Aspect Ratio = Aspect Ratio
Auto = 自動
Auto (1:1) = 自動 (1:1)
Auto (same as Rendering) = 自動 (同於轉譯解析度)