[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-i18n-doc
Subject: Multiple plural arguments
From: Kevin Krammer <krammer () kde ! org>
Date: 2012-10-28 19:19:44
Message-ID: 201210282019.44678.krammer () kde ! org
[Download RAW message or body]
Hi there!
Over at http://git.reviewboard.kde.org/r/107021/ we are discussing how to best
handle a case where the non-i18n handling would be a conditional concatenation
of strings.
The string would ultimately be something like
"Comments: 5, Likes: 3"
or
"Comments: 5" (no likes
or
"Likes: 3" (no comments)
This is currently done by conditionally appending ", " to the "Comments: ..."
string if comments and likes exist and then appending "Likes: ..." to the
result.
Another option I suggested but which can probably be improved on as well is to
have three strings, i.e.
i18n( "Comments: %1" )
i18n( "Likes: %1" )
i18n( "Comments: %1, Likes: %2" )
and then selecting the appropriate one.
While thinking a bit more about this I came across this variation:
i18np( "Comment:", "Comments:", numComments )
i18np( "Like:", "Likes:", numLikes )
i18nc( "Comment+Like merge pattern", "%1, %2" )
At this point I decided to go to the experts and ask them :)
Any thoughts on this?
Cheers,
Kevin
--
Kevin Krammer, KDE developer, xdg-utils developer
KDE user support, developer mentoring
["signature.asc" (application/pgp-signature)]
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic