after a lot of wrangling with waf, this should now be fixed. i checked ru.po and the plural forms appear to be there. <br><br>svn update will cause a complete rebuild, because waf has changed.<br><div class="gmail_extra"><br>
<br><div class="gmail_quote">On Fri, Jan 4, 2013 at 8:21 AM, Paul Davis <span dir="ltr"><<a href="mailto:paul@linuxaudiosystems.com" target="_blank">paul@linuxaudiosystems.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
the problem is that intltool needs to be told about P_() ....fixing that<br><br>%d only works if the code uses printf() and friends to format the message. we are using C++ and the type-safe "compose" mechanism, which uses %1. it won't be a problem.<div class="HOEnZb">
<div class="h5"><br>
<div class="gmail_extra"><br><br><div class="gmail_quote">On Fri, Jan 4, 2013 at 3:07 AM, Alexandre Prokoudine <span dir="ltr"><<a href="mailto:alexandre.prokoudine@gmail.com" target="_blank">alexandre.prokoudine@gmail.com</a>></span> wrote:<br>

<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Paul,<br>
<br>
Here's a quick overview of plural forms issues that still exist.<br>
<br>
First of all, ngettext suggests to use %d instead of %1. P_() macros<br>
doesn't work with %d. In fact, it doesn't even work with %1. Here are<br>
some examples:<br>
<br>
>From sfdb_ui.cc:<br>
<br>
                string_compose(P_("found %1 match", "found %1 matches", matches), matches));<br>
<br>
This never gets merged into PO files. Nor the other occurence of same<br>
phrase later in the file.<br>
<br>
>From ardour_ui.cc:<br>
<br>
if (tracks.size() != how_many) {<br>
                                error << string_compose (P_("could not create new audio track",<br>
"could not create %1 new audio tracks", how_many), how_many)<br>
                                      << endmsg;<br>
}<br>
<br>
Two issues in the example above:<br>
<br>
1. As already discussed on IRC, in Russian this won't work for numbers<br>
like 21, 41, 71 etc. There should always be a variable. I can submit<br>
English translation that deals with it to make the actual user visible<br>
phrase in English look more natural, i.e. the way it is now.<br>
<br>
2. Again, the combination of the P_() macros and the %1 variable<br>
doesn't work. Neither PO files get ngettextized, nor the actual<br>
phrases are put into PO files as is. After running ./waf i18n I get<br>
the "could not create %1 new audio tracks" phrase placed to the bottom<br>
of the PO file and marked as obsolete. Apparently gettext thinks that<br>
phrases inside P_() don't exist.<br>
<br>
When you think you fixed it, you can check if it worked by running<br>
./waf i18n and checking if the entry looks like this:<br>
<br>
#: ardour_ui.cc:1388<br>
#, fuzzy<br>
msgid "could not create %d new audio track"<br>
msgid_plural "could not create %d new audio tracks"<br>
msgstr[0] "first plural form translation"<br>
msgstr[1] "second plural form translation"<br>
msgstr[2] "third plural form translation"<br>
<br>
That's for Russian with its three plural forms.<br>
<br>
The other problem is that  "could not create a new mixed track"/"could<br>
not create %1 new mixed tracks" is not ngettextized in the source<br>
code. I tried fixing it by rewriting the code, but I'm obviously<br>
lacking required programming skills.<br>
<span><font color="#888888"><br>
Alexandre<br>
</font></span><div><div><br>
On Thu, Jan 3, 2013 at 6:19 PM, Paul Davis <<a href="mailto:paul@linuxaudiosystems.com" target="_blank">paul@linuxaudiosystems.com</a>> wrote:<br>
> should be improved and/or fixed in svn now. P_() is a new plural form i18n<br>
> macro.<br>
</div></div></blockquote></div><br></div>
</div></div></blockquote></div><br></div>