From kde-i18n-doc Sun Oct 28 19:19:44 2012 From: Kevin Krammer Date: Sun, 28 Oct 2012 19:19:44 +0000 To: kde-i18n-doc Subject: Multiple plural arguments Message-Id: <201210282019.44678.krammer () kde ! org> X-MARC-Message: https://marc.info/?l=kde-i18n-doc&m=135145202128502 MIME-Version: 1 Content-Type: multipart/mixed; boundary="--nextPart4202040.yFVNy6h2AN" --nextPart4202040.yFVNy6h2AN Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: quoted-printable Hi there! Over at http://git.reviewboard.kde.org/r/107021/ we are discussing how to b= est=20 handle a case where the non-i18n handling would be a conditional concatenat= ion=20 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: ..= =2E"=20 string if comments and likes exist and then appending "Likes: ..." to the=20 result. Another option I suggested but which can probably be improved on as well is= to=20 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 =2D-=20 Kevin Krammer, KDE developer, xdg-utils developer KDE user support, developer mentoring --nextPart4202040.yFVNy6h2AN Content-Type: application/pgp-signature; name=signature.asc Content-Description: This is a digitally signed message part. -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.12 (GNU/Linux) iD8DBQBQjYVQnKMhG6pzZJIRAiKSAJ98fSmdV35sQZpuM4mzKg+LI8MGOgCbBsfd 1I1PBMUBGLNAJ6MXLEOYWYE= =xdYF -----END PGP SIGNATURE----- --nextPart4202040.yFVNy6h2AN--