After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 763963 - Number of points does not appear translated at the end of the game
Number of points does not appear translated at the end of the game
Status: RESOLVED FIXED
Product: gnome-nibbles
Classification: Applications
Component: general
git master
Other Linux
: Normal normal
: ---
Assigned To: gnome-nibbles-maint
gnome-nibbles-maint
Depends on:
Blocks:
 
 
Reported: 2016-03-21 00:26 UTC by Gabor Kelemen
Modified: 2016-03-21 03:40 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Game over screen with score still in English (21.81 KB, image/png)
2016-03-21 00:26 UTC, Gabor Kelemen
  Details
Fix translations of score at end of game (1.03 KB, patch)
2016-03-21 03:40 UTC, Michael Catanzaro
committed Details | Review

Description Gabor Kelemen 2016-03-21 00:26:43 UTC
Created attachment 324400 [details]
Game over screen with score still in English

At the end of the game I get the final score untranslated as "xx Points".

This is because the ngettext call supposed to localize the string is incorrect in gnome-nibbles.vala:

        var score_string = ngettext ("%d Point".printf (score), "%d Points".printf (score), score);

"%d Point".printf (score) doesn't work like expected: I think it substitutes %d with the actual score, then ngettext looks for localization of the string containing a number, not %d.
Comment 1 Michael Catanzaro 2016-03-21 03:40:23 UTC
Thanks for another good bug report.

The following fix has been pushed:
539b8a2 Fix translations of score at end of game
Comment 2 Michael Catanzaro 2016-03-21 03:40:28 UTC
Created attachment 324408 [details] [review]
Fix translations of score at end of game