Dil tanımları

Farklı çevirileri doğru bir şekilde sunmak için dil adı, metin yönü, çoğul tanımları ve dil kodu hakkında bilgiler gereklidir.

Dil kodlarını ayrıştırma

Çevirileri ayrıştırırken, Weblate dil kodunu (genellikle ISO 639-1 olanı) herhangi bir mevcut dil nesnesine eşlemeye çalışır.

Dil kod adları ile bu eşlemeyi proje düzeyinde daha fazla ayarlayabilirsiniz.

Tam eşleşme bulunamazsa, mevcut bir dile en iyi şekilde uydurulmaya çalışılır. Aşağıdaki adımlar denenir:

  • Büyük/küçük harfe duyarlı olmayan aramalar.

  • Alt çizgileri ve kısa çizgileri normalleştirme.

  • Yerleşik dil kod adlarında arama.

  • Dil adına göre arama.

  • Belirli bir dil için varsayılan ülke kodunu yok sayma—cs_CZ yerine cs seçme.

Bunun da başarısız olması durumunda, varsayılanlar kullanılarak (soldan sağa metin yönü, bir tane çoğul) yeni bir dil tanımı oluşturulacaktır. xx_XX koduyla otomatik olarak oluşturulan dil xx_XX (generated) olarak adlandırılacaktır. Bunu daha sonra yönetici arayüzünde değiştirmek (bkz: Changing language definitions) ve sorun izleyiciye bildirmek (bkz: Weblate’e Katkıda Bulunma) isteyebilirsiniz, böylece uygun tanımın gelecek Weblate sürümüne eklenmesini sağlayabilirsiniz.

İpucu

Dil olarak istenmeyen bir şey görürseniz, çevirileri ayrıştırırken bu tür bir dosyayı yok saymak için Dil süzgeci ayarlamak isteyebilirsiniz.

Ayrıca bakınız

Dil kodu, Adding new translations

Changing language definitions

You can change language definitions in the languages interface (/languages/ URL).

While editing, make sure all fields are correct (especially plurals and text direction), otherwise translators will be unable to properly edit those translations.

Yerleşik dil tanımları

Definitions for about 600 languages are included in Weblate and the list is extended in every release. Whenever Weblate is upgraded (more specifically whenever weblate migrate is executed, see Generic upgrade instructions) the database of languages is updated to include all language definitions shipped in Weblate.

This feature can be disable using UPDATE_LANGUAGES. You can also enforce updating the database to match Weblate built-in data using setuplang.

Belirsiz dil kodları ve makro diller

In many cases it is not a good idea to use macro language code for a translation. The typical problematic case might be Kurdish language, which might be written in Arabic or Latin script, depending on actual variant. To get correct behavior in Weblate, it is recommended to use individual language codes only and avoid macro languages.

Dil tanımları

Each language consists of following fields:

Dil kodu

Code identifying the language. Weblate prefers two letter codes as defined by ISO 639-1, but uses ISO 639-2 or ISO 639-3 codes for languages that do not have two letter code. It can also support extended codes as defined by BCP 47.

Dil adı

Visible name of the language. The language names included in Weblate are also being localized depending on user interface language.

Metin yönü

Determines whether language is written right to left or left to right. This property is autodetected correctly for most of the languages.

Plural number

Number of plurals used in the language.

Çoğul formülü

Gettext compatible plural formula used to determine which plural form is used for given count.

Adding new translations

2.18 sürümünde değişti: In versions prior to 2.18 the behaviour of adding new translations was file format specific.

Weblate can automatically start new translation for all of the file formats.

Some formats expect to start with an empty file and only translated strings to be included (for example Android string resources), while others expect to have all keys present (for example GNU gettext). The document-based formats (for example OpenDocument Format) start with a copy of the source document and all strings marked as needing editing. In some situations this really doesn’t depend on the format, but rather on the framework you use to handle the translation (for example with JSON files).

When you specify Yeni çeviriler için şablon in Component configuration, Weblate will use this file to start new translations. Any exiting translations will be removed from the file when doing so.

When Yeni çeviriler için şablon is empty and the file format supports it, an empty file is created where new strings will be added once they are translated.

The Dil kodu stili allows you to customize language code used in generated filenames:

Dosya biçimine göre varsayılan

Dependent on file format, for most of them POSIX is used.

Ayırıcı olarak alt çizgi kullanan POSIX stili

Typically used by gettext and related tools, produces language codes like pt_BR.

Ülke kodu da dahil olmak üzere ayırıcı olarak alt çizgi kullanan POSIX stili

POSIX style language code including the country code even when not necessary (for example cs_CZ).

Ayırıcı olarak kısa çizgi kullanan BCP stili

Typically used on web platforms, produces language codes like pt-BR.

Ülke kodu da dahil olmak üzere ayırıcı olarak kısa çizgi kullanan BCP stili

BCP style language code including the country code even when not necessary (for example cs-CZ).

Android stili

Only used in Android apps, produces language codes like pt-rBR.

Java tarzı

Used by Java—mostly BCP with legacy codes for Chinese.

Additionally, any mappings defined in Dil kod adları are applied in reverse.

Not

Weblate recognizes any of these when parsing translation files, the above settings only influences how new files are created.