Bug #1633

Translation issues

Added by terencehill about 1 year ago. Updated 3 months ago.

Status:NewStart date:06/05/2013
Priority:NormalDue date:
Assignee:Samual% Done:

0%

Category:-
Target version:0.8

Description

1. Is this string correct?
_("^BG%s^F3 connected and joined the ^TC^TT\n")
It appears as: xxx connected and joined the RED

2. ^TC^TT is used to indicate the color of teams, flags and keys, but in other languages it may be translated differently depending on the genre/form of the relative noun.

3. I noticed that the console messages (MSG_INFO_NOTIF) always have a final \n. I was thinking that it could be good to strip it out from the translatable strings and add it dinamically in the MSG_INFO_NOTIF macro.
This change would make these messages slightly easier to be translated and it would reduce number of messages to be translated as a few messages only differ for that \n (e.g. notifications.qh, lines 334-339 509-514). Another benefit is that it would make impossible to forget \n when adding a new message in the code.

History

#1 Updated by Samual about 1 year ago

  • Target version changed from 0.7 to 0.8

#2 Updated by terencehill 6 months ago

The issue #3 has been resolved long time ago.

About #1 and #2, here it's a more complete report:

TEAM NAMES TRANSLATION
Currently team names can't be correctly translated into many (if not all) Romance languages (it, fr, es, etc...) since joining separated translations for "<color>" and "team" doesn't always work. In these languages adjective-noun positions are usually inverted (there are exceptions though!) and the adjective gender must agree with the noun gender (M or F).

SPELLING CONSISTENCY IN THE ENGLISH MESSAGES
  • different spelling of team names, e.g.: "RED team", "Red Team", even "RED".
  • "Key" is always capitalized while "flag" is always lowercase even though they are used in the same way, e.g.: "RED flag", "Red Key".
  • different ways of coloring team names: it's often used "^TC^TT^BG team" but sometimes "^TC^TT team" too (in the former "team" is not meant to be team-colored by ^TC).

#3 Updated by terencehill 6 months ago

Possible solutions:

SOLUTION #1 implemented in terencehill/translatable_strings_fixes

TEAM NAMES TRANSLATION
_("team") has been replaced by _("%s team"); if the translation of "team" is feminine, this must be indicated with the tag "F^"
e.g. _("%s team") --> "F^squadra %s"
At run time %s gets replaced by the femenine version of the color _("F^<color>") rather then by the default _("<color>")

"^TT team" inside messages (^TT stands for _("<color>")), has been replaced by ^TEAM, which stands for _("%s team")

Same thing for flag and key:
"^TT flag" replaced with ^FLAG stands for _("%s flag")
"^TT key" replaced with ^KEY stands for _("%s key")

SPELLING CONSISTENCY IN THE ENGLISH MESSAGES
  • team name is always spelled in the same way, e.g. "Red team"
  • flags and keys are always lowercase, like team names, e.g. "Red flag"
  • "^TC^TT team" and "^TC^TT^BG team" have been replaced by "^TC^TEAM^BG", which doesn't need to be translated nor modified ("^TC^TT team" translated into Italian becomes "^TCsquadra ^TT") and guarantes a consistent coloring of team names

These are the strings and translations required by this implementation:

_("F^Red") --> "Rossa" 
remaining colors ...
_("%s team") --> "F^squadra %s" 
_("%s flag") --> "F^bandiera %s" 
_("%s key") --> "F^chiave %s" 
"... ^TC^TEAM^BG ..." doesn't need to be translated

Please note that migration from "^TT xxx" to ^TEAM/^FLAG/^KEY in the translated messages is a matter of search-replace for most if not all the existing translation, I can take care of it.

SOLUTION #2 (simplified #1)

A modified implementation of SOLUTION #1 wouldn't require neither individual colors nor gender specification, at the cost of introducing redundant strings:

_("Red team") --> "squadra rossa" 
remaining colors ...
_("Red flag") --> "bandiera rossa" 
remaining colors ...
_("Red key") --> "chiave rossa" 
remaining colors ...
"... ^TC^TEAM^BG ..." doesn't need to be translated

SOLUTION #3

_("F^Red") --> "F^Rossa" 
other colors ...
_("team") --> "F^squadra" 
_("flag") --> "F^bandiera" 
_("key") --> "F^chiave" 
_("%s %s") --> "%2$s %1$s" 
"... ^TC^TT^BG team ..." --> "... F^squadra ^TC^TT^BG ..." 
"... ^TC^TT team ..." --> "... ^TCF^squadra ^TT ..." 

#4 Updated by terencehill 6 months ago

IMO even if the solution #1 is more clever, I think that the best solution is #2: easy to implement, easy to translate.

#5 Updated by terencehill 3 months ago

Translation files have been updated lately, I would have liked to see this change already in master before that so that translators can work on these new strings...

Also available in: Atom PDF