Template:Rtl-lang/doc

Usage
This template behaves like lang, but additionally inserts the  parameter in the span, and adds the &amp;lrm; character at the end of the span.

Note that this is not required for normal insertion of a string in a left-to-right script. If you don't know what you are doing, use lang.

For example, to produce strings in Arabic or Hebrew script, simply use:
 * The romanization of "اللغة العربية" is "al-luġah al-‘arabiyyah".
 * The romanization of "עברית" is "‘Ivrit".
 * Қазақ тілі (قازاق ڌﻳل)

which yields
 * The romanization of "اللغة العربية" is "al-luġah al-‘arabiyyah".
 * The romanization of "עברית" is "‘Ivrit".
 * Қазақ тілі (قازاق ڌﻳل)

Inline use of the   parameter will be restricted to very rare cases, such as use of Arabic letters as symbols in mathematical formulas, or several levels of nested ltr-within-rtl-within-ltr.

Further note that
 * For the 'direction' property to affect reordering in inline-level elements, the 'unicode-bidi' property's value must be 'embed' or 'override'.

and that the point of the   parameter is proper line-breaking behavior: if a linebreak separates اللغة العربية, it should be "العربية", not "اللغة" that is taken to the next line.