views:

175

answers:

1

I'm trying to get my head around i18n with Catalyst. As far as I understood the matter, there are two ways to make translations with Perl: Maketext and Gettext. However, I have a requirement to support gettext's .po format so basically I'm going with gettext.

Now, I've found Catalyst::Plugin::I18n and thus Locale::Maketext::Lexicon, which does what I want most of the time. However, it doesn't generate proper pluralization forms, i.e. properly writing msgid_plural and msgstr[x] into the .pot file. This happens probably because Maketext depends on its bracket notation [quant,_1...] and thus has to have the same notation in the translation.

Yet another solution might be using some direct gettext port like Locale::Messages, however this would mean rewriting C::P::I18n.

Does anybody have a proper solution for this problem apart from rewriting several modules? Anything that combines proper gettext with all its features and Catalyst will do.

+2  A: 

You will probably get a better answer on the mailing list:

http://lists.scsys.co.uk/cgi-bin/mailman/listinfo/catalyst

I assume you've also read this:

http://www.catalystframework.org/calendar/2006/18

jrockway
Of course I've read that, but it's mostly talking about C::P::I18N which I've mentioned would need some patching...
rassie
Which is why I suggested you ask your question somewhere with Catalyst users.
jrockway