[Potlatch-dev] Internationalization
Dave Stubbs
osm.list at randomjunk.co.uk
Tue Aug 31 14:34:00 BST 2010
On Tue, Aug 31, 2010 at 12:31 PM, Andy Allan <gravitystorm at gmail.com> wrote:
> On Tue, Aug 31, 2010 at 11:48 AM, Ævar Arnfjörð Bjarmason
> <avarab at gmail.com> wrote:
>
>>> P2 is a slightly different kettle of fish because Flex is involved. You
>>> can't just pull stuff in at runtime (as P1 does) without making the .mxml
>>> files unspeakably horrible.
>>
>> Yeah, I haven't looked at how to do it in PL2...
>
> [...]
>
>> Anyway, whatever PL2 ends up going for I'd be happy to help with it.
>
> Just to say that I'm interested in seeing the i18n side of things
> getting going sometime in the next couple of months. I know very
> little about i18n, and even less about what makes a good/bad setup, so
> I'm looking to others. I'm happy to plug through the code and do the
> boring work (like I did for the rails_port back in May 09) but if
> someone else can recommend the framework and/or do the first couple of
> i18n examples that would be great.
>
The framework Richard pointed at is the most promising I've found.
Essentially you leave the English in the source (which makes it
readable), but it's not really used as it's replaced by a resource at
run time. It uses the standard Flex l10n mechanisms but does so
without screwing up your code. The resources get packaged as separate
files, and this is the biggest change as I think there would need to
be an ant build step (the Java version of make) which so far we've
avoided by being pretty simplistic.
Flex resources essentially end up as key=value property files which
I'm guessing translatewiki should be able to handle without too much
difficulty.
The biggest problem with that framework is that it does appear to work
by magic. How to use it seems fairly simple, but I've no idea how it
gets from that to translated application :-)
Dave
More information about the Potlatch-dev
mailing list