Patch #1299

Polish translation for r1460

Added by Leszek Ciesielski over 9 years ago. Updated almost 9 years ago.

Status:ClosedStart date:2008-05-26
Priority:NormalDue date:2008-11-07
Assignee:Azamat Hackimov% Done:

0%

Category:Translations
Target version:0.8

Description

I wanted to attach a patch with translatoins of the new strings, but I have a problem:
the strings mail_subject_reminder and mail_body_reminder need 3 different translations in polish (for 1/2--4/5+ items). How can this be done? I know it has something to do with _gloc_rule_default, but after that, I'm clueless.

new_gloc.diff Magnifier (5.23 KB) Leszek Ciesielski, 2008-11-04 17:42

polish.txt Magnifier (5.64 KB) Leszek Ciesielski, 2008-11-05 16:39

Associated revisions

Revision 1986
Added by Azamat Hackimov almost 9 years ago

Update for pl.yml, #1299

History

#1 Updated by Jean-Philippe Lang over 9 years ago

  • Status changed from New to Closed

See #1635.

#2 Updated by Azamat Hackimov over 9 years ago

Hi.

I'm just want warn, _gloc_rule_default for polish must be different than for russian. See gettexxt manual for plural forms for language families: http://www.gnu.org/software/autoconf/manual/gettext/Plural-forms.html

I'm not Ruby hacker, but for polish _gloc_rule_default may be look like that:

_gloc_rule_default: '|n| n10=n%10; n100=n%100; n==1 ? "" : n10>=2 && n10<=4 && (n100<10 || n100>=20) ? "_plural234" : "_plural5"'

Maybe I'm wrong, but как-то так :)

#3 Updated by Leszek Ciesielski almost 9 years ago

  • Status changed from Closed to Reopened

I did check how the ru translation has changed, but I am still confused.

I checked your _gloc_rule_default against http://doc.trolltech.com/qq/qq19-plurals.html - and it is the same. And it sounds right :-) However, I have one further question - when I change the gloc rule and add translations for _plural234 and _plural5 variants, should I leave the _plural variant in the translations file? Also, does each _plural language string need to be changed to _plural234 + _plural5 or do only those with % formatting included need this?

#4 Updated by Azamat Hackimov almost 9 years ago

Hard to answer. Some strings require _plural form only (Projects, for example). That beacause some strings not true "plural", it's just string without any counting variables. You can consult ru.yml lang-file - I checked each plural string manually.

#5 Updated by Leszek Ciesielski almost 9 years ago

I prepared a patch with the new Polish gloc rule and updated plural translations (using ru.yml as a list of which plural versions were required).

However, no translation provides a plural and singular version for the one string that cause me to initially open this ticket. Grepping through application code I found:
app/models/mailer.rb: subject l(:mail_subject_reminder, issues.size)
Does this allow the use of various translations based on issues.size?

#6 Updated by Leszek Ciesielski almost 9 years ago

Added translation of missing strings (as per r1977 ), consistent with previous ones.

I have doubts about translation of 'news' and 'messages', previously they all got translated as 'wiadomości' so I used this in new strings as well. I do not know how this could be clarified - perhaps 'news' as 'komunikaty', 'messages' as 'wiadomości'. Any Polish speakers here?

This patch is separate from the gloc one.

#7 Updated by Azamat Hackimov almost 9 years ago

  • Due date set to 2008-11-07
  • Status changed from Reopened to Closed
  • Assignee set to Azamat Hackimov
  • Target version set to 0.8

Leszek Ciesielski wrote:

However, no translation provides a plural and singular version for the one string that cause me to initially open this ticket. Grepping through application code I found:
app/models/mailer.rb: subject l(:mail_subject_reminder, issues.size)
Does this allow the use of various translations based on issues.size?

By design this should allow plural form. But without "_plural" it can't be interpreted as plural form and treated as singular. I'll think about it and try fix this.

Anyway, update commited.

Also available in: Atom PDF