[Bug 15395] Internationalization: plural forms, context, and more
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=15395 --- Comment #61 from Julian Maurice <julian.maurice@biblibre.com> --- (In reply to paxed from comment #60)
(In reply to Jesse Weaver from comment #57)
Created attachment 70974 [details] [review] [review] Bug 15395: Example usage of I18N Template::Toolkit plugin
Moved this patch for example usage to teh end of patch set and resolved minor conflict while applyin Signed-off-by: Marc Véron <veron@veron.ch>
I'm confused by this example. How does the msgid look like in the po-file?
msgid "item" msgid_plural "items"
Like that?
If so, then that's a bad example, as it's basically the same as concatenating number + "item" The number placeholder should be included in the translatable string, so the msgid looks like this:
msgid "one item" msgid_plural "%s items"
Because the translator can then actually make it sound natural in their own language - perhaps the language needs an article before the number, or a suffix to the number, both of which would be impossible to do with the original example.
The problem solved by this example is not the concatenation of the number and the "item/items" string, but the fact that it allows only two forms (one singular, one plural), which is ok for some languages, but not for all. But I agree that it can be improved. I will submit another patch. -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org