Re: [PATCH] Add L10N percentages to translation strings.
"Kevin J. McCarthy" <[email protected]> Fri, 1 May 2026 20:41:37 +0800
| Newsgroups | gmane.mail.mutt.devel |
|---|---|
| Message-ID | <afSfgfyMbZPCrCVD@qinghai> |
On Fri, May 01, 2026 at 08:20:41PM +0800, Kevin J. McCarthy wrote:
>On Fri, May 01, 2026 at 12:19:34PM +0200, Oswald Buddenhagen via Mutt-dev wrote:
>>the subject and (lack of) description left me guessing what this
>>patch even is about, so you may want to expand it.
>>
>>also, to be super-pedantic, you are adding "i18n of percentages".
>>l10n is the process of populating the .po files with actual
>>translations.
>>this affects the naming in the code as well.
>
>The L10N flags on the comments end up as comments to the translators.
I apologize for my snippy reply. Replying to myself, let me see if I
can try again.
You're talking about the function name. I'll change it. Thanks for the
correction.
>>On Fri, May 01, 2026 at 12:47:11PM +0800, Kevin J. McCarthy wrote:
>>>+++ b/curs_lib.c
>>>- mutt_message("%s %s/%s (%d%%)", progress->msg, posstr, progress->sizestr,
>>>+ mutt_buffer_addstr(messagefmt, "/%s (");
>>>+ mutt_buffer_addstr(messagefmt, mutt_l10n_percentage());
>>>+ mutt_buffer_addstr(messagefmt, ")");
>>>
>>it's kind of funny to see that in a patch that improves i18n,
>>because such word puzzles are about as i18n-hostile as it gets. of
>>course it doesn't actually matter here, because that format string
>>isn't i18n'd - but maybe it should be? conventions on ordering and
>>parenthesizing things vary between locales.
>
>This was suggested by a translator, I merely cleaned it up. So
>apparently it's useful to at least one of the Mutt translators.
>
>I don't think doing it for the whole format string would help. Maybe
>you were being funny too, though?
I agree the curs_lib.c part of the patch is a bit of a puzzle. It's
because the percentage needs to be inserted dynamically. I could put
the initial "%s %s" in each piece, but I still don't think it would make
it much clearer.
I was already a bit apprehensive about i10n the percentages, so I would
be reluctant to take on localization of the whole string.
--
Kevin J. McCarthy
GPG Fingerprint: 8975 A9B3 3AA3 7910 385C 5308 ADEF 7684 8031 6BDA
signature.asc
(application/pgp-signature, 833 B)
-----BEGIN PGP SIGNATURE----- iQIzBAEBCgAdFiEEiXWpszqjeRA4XFMIre92hIAxa9oFAmn0n4EACgkQre92hIAx a9qzVBAArGlZKeGRaAfG3tRG+F9w9uBbtXqPvzEiswry+KCSp/cvGwZE8rLcoe+2 yt69pZNmeSM4L54Xop9tfks3Ok6ACnolhCWzxlv25FbsB4ORtJl5vpM9G0WrRUet Jq/wu0u3NkIAsE8dboVB8uNInVU6VYUUItU2mCcP6gjYqAWhvWjUN5wXPXWF/gYo P2hNUL9WAh1SwoDu4/NRBLxz6KmTCrFWTctQegF05wptT2vGNBlkienjjZv+lgRu 2Av4EjloMq3BTqibawYouAYFxH5H8oxGgZ92mtncY9xmDQRDkHn7POUEM4ZEkp5j i0rzjvAZIzOgkODyqkPmwltiF5FVTN3GBlM0aAVnNEtOJNeXlEPSgwUa85SUUfj+ TLDPFI1PRRJaJ7qhkaNcS/7K37ReH7oeGFxo7BMUKCCoH/x/xY2vRQjygZqcVMqr 1Q0Rgq0iI3IV0P13DQxcQZN3+cHyU+MvIkVmIaLDU1s/vWTzNyqsQO6FxAmCm8ZM Nz2tKUG+iBpMtQ4JJdNVoH4z4ynt3Ga+L600anHbVVpGPjDW7jcyqL+AnH7C4ao0 zHbSpPAKOiFQxUSmKxfFVlUAWlpygXBBapCP/pek2I8z3EbGbz6lcm6jCEtwLKFQ oAeYdHwNZrdzulrWElZwT/OEdO1s712qpi5C8CWAAPAXCESB8c4= =DQ/Z -----END PGP SIGNATURE-----