Update explanation in Language Support

* Explain new implementation of close matches.
* Wrapped lines at 80 characters.
This commit is contained in:
sibir-ine
2021-04-09 04:46:30 -07:00
parent 0eace4b404
commit 06ce61de88
+15 -1
View File
@@ -44,7 +44,21 @@ Messages are given as key-value maps.
Language Support
----------------
If a message's ``content`` value is a string, the message will use the string as its content if displayed. Otherwise, the first localised content structure with a language that matches LOOT's current language will be used as the message's content if displayed. If there are no matches, then the first structure in English will be used.
If a message's ``content`` value is a string, the message will use the string as
its content if displayed. Otherwise, the first localised content structure with
a language or locale code that matches LOOT's current language will be used as
the message's content if displayed. If there are no exact matches, LOOT will try
to find a close match. If LOOT's current language uses a locale code, it will
display the first structure with the same language code, but not another locale
code with the same language code. For example, if LOOT's current language has
locale code ``pt_BR``, it will display the first structure with language code
``pt`` (but not locale code ``pt_PT``) if none exist with locale code ``pt_BR``.
If LOOT's current language has a language code, it will display the first
structure with a locale code that contains that language code. For example, if
LOOT's current language has language code ``pt``, it will display the first
structure with locale code ``pt_PT`` or ``pt_BR`` if none exist with language
code ``pt``. If there are no exact or close matches, then the first structure in
English will be used.
Equality
--------