Module:Lang-hbs/doc

This module produces equivalent Serbo-Croatian Latin text from Cyrillic input.

Usage
This module exports two functions providing different outputs. Both functions require text argument for proper operation.

cyr2lat and lat2cyr
These function should be invoked the following way:

&#123;{#invoke:lang-hbs|cyr2lat|text to be converted}} &#123;{#invoke:lang-hbs|lat2cyr|text to be converted}}

It replaces all letters of Serbo-Croatian Cyrillic alphabet with corresponding Latin letters.

Note: per MOS:FOREIGN non-English words in Latin script should be italicized. fuction leaves it to users.

convert
This function should be invoked the following way:

&#123;{#invoke:lang-hbs|concat|cyrillic=Cyrillic text|latin=Latin text}}

It replaces Serbo-Croatian Cyrillic with Latin and returns both Cyrillic and Latin text with latter being italicized. Either of cyrillic and latin is sufficient.

Caveats

 * Serbo-Croatian Latin alphabet includes letters "ǉ", "ǌ" and "ǆ", which, in addition to upper case ("Ǉ", "Ǌ" and "Ǆ" respectively), also have "title case" ("ǈ", "ǋ" and "ǅ"), which is used when only individual letters of the word are capitalized (eg. name "Љиљана" is spelled as "ǈiǉana", not "Ǉiǉana"). For performance and algorythmic complexity reasons this template always uses title case instead of upper case.
 * Latin to Cyrillic transliteration works only with Unicode digraphs. Use Cyrillic to Latin transliteration if in doubt.