*****SPAM*****Plural forms in the style KCM

Freek de Kruijf freekdekruijf at kde.nl
Wed Sep 2 09:12:32 BST 2026


Op woensdag 2 september 2026 08:52:23 Midden-Europese zomertijd schreef Ingo 
Klöcker:
> On Mittwoch, 2. September 2026 07:51:23 Mitteleuropäische Sommerzeit Yuri
> 
> Chornoivan wrote:
> > https://invent.kde.org/plasma/plasma-workspace/-/blob/master/kcms/style/
> > 
> > kcmstyle.cpp?ref_type=heads#L225:
> >             message = i18ncp("@info:status",
> >             
> >                              "Successfully uninstalled “%2” but could not
> > 
> > uninstall others:\n",
> > 
> >                              "Successfully uninstalled %1 styles but could
> > 
> > not uninstall others:\n",
> > 
> >                              uninstalled.size(),
> >                              uninstalled.first());
> > 
> > https://invent.kde.org/plasma/plasma-workspace/-/blob/master/kcms/style/
> > kcmstyle.cpp?ref_type=heads#L237:
> > 
> > i18ncp("@info:status", "Successfully uninstalled “%2”.", "Successfully
> > uninstalled %1 styles.", uninstalled.size(), uninstalled.first()));
> > 
> > It seems that this will not work for the languages with more than 2 plural
> > forms. Am I right?
> 
> I would expect it to work (unless i18ncp complains about the missing %2 in
> the second string). Why do you think it wouldn't work? If the number is 1
> then the first string is used. In all other cases the matching plural form
> (as translation of the second string) in the target language will be used.
> I don't see how this is different from any other usage of i18ncp in our
> source code.
> 
> Regards,
> Ingo

It also does not work in a language with 1 plural, Dutch. The translation was 
not accepted.

-- 

vr.gr.

Freek de Kruijf
vertaler/coördinator van KDE





More information about the kde-i18n-doc mailing list