[Mediawiki-i18n] RTL-lang messages in a multilingual wiki

Rotem Liss rotemliss_net at fastmail.fm
Fri Mar 2 12:24:01 UTC 2007


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Brianna Laugher wrote:
> Hello,
> 
> Please compare
> http://commons.wikimedia.org/w/index.php?title=Special:Userlogin&uselang=he&type=signup
> to
> http://he.wikipedia.org/w/index.php?title=Special:Userlogin&uselang=he&type=signup
> 
> On Commons, the messages appear RTL text direction which is correct,
> but on the left, which I imagine is as unnatural as right-aligning for
> English.
> 
> Evidently there is some sitewide setting for he.wp that tells it to
> display messages right aligned. Commons default language is English
> which is left aligned. I guess that using uselang=he is not enough for
> it to display messages right aligned?
> 
> Should we (Commons) go and insert <span align="right"> around every /he message?
> Would this solve it?
> (Would this be a *good way* to solve it?)
> 
> thanks,
> Brianna
> user:pfctdayelise
> 

First, not all the messages can use HTML, and even Wikitext, so this may fail.
Second, several messages don't need this. Third, this won't fix the interface as
the whole page is LTR-aligned. Fourth, the problem is not "align" but
"direction": direction means the general direction of the paragraph, and the
default align if not set. If you just set <span align="right">, this will make
the points (".") appear in the right instead of the left. It should be <span
dir="rtl">, but this won't work either, from the above reasons.

Actually, *there is* a setting of direction: the variable $rtl in the messages
file. If it is set to true, the wiki is RTL; if not, the wiki is LTR. This works
very good in RTL wikis. RTL languages set "$rtl = true", and LTR languages set
"$rtl = false" (or let it fall back to the English default, which is false).
"$rtl" is read *from the content language files*, i.e. the default language of
the site. Since the default language of Commons is English, the setting is LTR.
This is good for most pages, because it also sets the directions of pages.

If the interface language (the user-selected language) direction is different
than the content language (the site default language) direction, *the content
language direction is used* for everything. This can and should be changed - the
interface direction should be used for the interface, and Bug 6100 (
http://bugzilla.wikimedia.org/show_bug.cgi?id=6100 ) is about it.

This has nothing to do with Multilingual MediaWiki.

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFF6BcSqahN/0dU8mcRAgexAKCo14wE/Kr7Y0rBmby29DHRD9HqmACeJ66o
gfKskvcIaoscP3dlwLFnJHw=
=Ps5p
-----END PGP SIGNATURE-----



More information about the Mediawiki-i18n mailing list