Re: [PATCH] advice: omit trailing whitespace

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Rubén Justo <rjusto@xxxxxxxxx> writes:

>> >  	for (cp = buf.buf; *cp; cp = np) {
>> >  		np = strchrnul(cp, '\n');
>> > -		fprintf(stderr,	_("%shint: %.*s%s\n"),
>> > +		fprintf(stderr,	_("%shint:%s%.*s%s\n"),
>> >  			advise_get_color(ADVICE_COLOR_HINT),
>> > +			(np == cp) ? "" : " ",
>> >  			(int)(np - cp), cp,
>> >  			advise_get_color(ADVICE_COLOR_RESET));
>
> Thinking again on this I wonder, while we're here, if we could go further
> and move the "hint" literal to the args, to ease the translation work:
> -               fprintf(stderr, _("%shint:%s%.*s%s\n"),
> +               fprintf(stderr, "%s%s:%s%.*s%s\n",
>                         advise_get_color(ADVICE_COLOR_HINT),
> +                       _("hint"),
>                         (np == cp) ? "" : " ",
>                         (int)(np - cp), cp,
>                         advise_get_color(ADVICE_COLOR_RESET));

It is not guaranteed that any and all languages want to use a colon
immediately after translation of "hint"; the current message string
with or without my patch allows translators adjust that part to the
target language, but your version will force them to always use only
a colon there.  Is that an improvement?  I somehow do not think so.






[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux