On Mar 25, 2007, at 11:54 PM, Sergiu Dumitriu wrote:
On 3/25/07, Vincent Massol <vincent(a)massol.net> wrote:
On Mar 24, 2007, at 10:55 PM, Pavel wrote:
Greetings,
There is a number of ApplicationResources_xx.properties in XWiki
and it looks like all of them are different (contain different set
of keys).
Both ApplicationResources.properties and
ApplicationResources_en.properties are in english and are mostly
identical except for ~70 missing keys in _en file.
Given that, I have two questions:
1. What is the "most supported" message resources file?
ApplicationResources.properties
Indeed, with a minor observation that a few entries in
AR_en.properties override the ones in AR.properties.
1) When a key is missing it's looked for in
AppliationResources.properties . This allows any language to work even
if there are missing keys.
2) I don't know why we have a AppplicationResources_en.properties as
it's supposed to be the same as ApplicationResources.properties. IMO
we should remove it
In theory, if somebody decides to deploy a wiki mainly used in
russian, for example, he could replace AR.properties with
AR_ru.properties as the default resource bundle.
AFAIK there's no default resource bundle. Or rather there's one but
it's always named without the country and language suffixes. Unless
I'm mistaken of course :)
The, in order for the english translation to work,
AR_en.properties
should exist.
However, maintaining two resource files is not needed, as if
someone knows how to replace AR.properties, he should know how to
create the backup AR_en.properties.
In an ideal world (to be read: a world without Microsoft and
Windows) AR.props should be a symlink to the actual language file.
So, +1 for removing AR_en.properties.
2. Are all messages from .properties used in
XWiki, or some are
redundant?
It's possible that some messages are no longer used.
Almost all messages are used, but in different skins. One thing we
can do to ease the work would be to copy the current resource files
into the dodo skin directory, and declare it as deprecated, so that
we can move on with the new skins.
It makes sense to me that AR files should be in their own skins,
except for messages for templates.
If the latter,
are there plans for removal of unnecessary keys for
1.0 release?
Sure, if you want to help you can tell us which ones are no longer
used, submit a patch and we'll remove them.
Note that we also have some work to do in the future on the message
to use sentences instead of just words. This will allow languages not
using the same word ordering than enlglish to provide a translation
for XWiki.
Is there a JIRA issue for this? I remember seeing this, but I don't
know if it was in a mail only, or on JIRA, too.
No idea...
Thanks
-Vincent