Some strings require fixed order of variables: translation issue
Bug #176683 reported by
sander
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
Coccinella |
Fix Released
|
Wishlist
|
Mats |
Bug Description
Some strings require a fixed order of variables. This makes a good translation in some languages (extremely) hard, if not impossible.
Examples:
Cannot read %s: %s
Cannot download file %s from %s.
etc
Solution: use different variables like this:
Cannot read %s: %t
Cannot download file %s from %t.
etc
URL: http://
Changed in coccinella: | |
assignee: | nobody → matsben |
importance: | Undecided → Wishlist |
To post a comment you must log in.
There is a solution for this:
() 1 % format "This is the %s and %s attempt" FIRST SECOND
This is the FIRST and SECOND attempt
() 3 % format {This is the %2$s and %1$s attempt} FIRST SECOND
This is the SECOND and FIRST attempt
See: http:// tcl.tk/ man/tcl8. 4/TclCmd/ msgcat. htm#M18 tcl.tk/ man/tcl8. 4/TclCmd/ format. htm#M5
and http://
msgcat uses the 'format' command.
In short, the translator must add "positional codes".
Perhaps worth a note somewhere?
On 12/16/07, Launchpad Bug Tracker <email address hidden> wrote: lists.jabber. ru/pipermail/ ejabberd/ 2007-December/ 003298. html /bugs.launchpad .net/bugs/ 176683
> You have been subscribed to a public bug:
>
> Some strings require a fixed order of variables. This makes a good
> translation in some languages (extremely) hard, if not impossible.
>
> Examples:
> Cannot read %s: %s
> Cannot download file %s from %s.
> etc
>
> Solution: use different variables like this:
> Cannot read %s: %t
> Cannot download file %s from %t.
> etc
>
> URL: http://
>
> ** Affects: coccinella
> Importance: Wishlist
> Assignee: Mats (matsben)
> Status: New
>
> --
> Some strings require fixed order of variables: translation issue
> https:/
> You received this bug notification because you are a bug assignee.
>