git@vger.kernel.org mailing list mirror (one of many)
 help / color / mirror / code / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: "Ævar Arnfjörð Bjarmason" <avarab@gmail.com>
Cc: "Julien Palard" <julien@palard.fr>,
	"git@vger.kernel.org" <git@vger.kernel.org>,
	"Sébastien Helleu" <flashcode@flashtux.org>,
	"Jean-Noël Avila" <jn.avila@free.fr>
Subject: Re: [PATCH] Make a colon translatable
Date: Tue, 12 Apr 2022 09:32:53 -0700	[thread overview]
Message-ID: <xmqq35iicle2.fsf@gitster.g> (raw)
In-Reply-To: <220412.86tuayhga7.gmgdl@evledraar.gmail.com> ("Ævar Arnfjörð Bjarmason"'s message of "Tue, 12 Apr 2022 10:03:48 +0200")

Ævar Arnfjörð Bjarmason <avarab@gmail.com> writes:

>>> --- a/wt-status.c
>>> +++ b/wt-status.c
>>> @@ -248,7 +248,7 @@ static void wt_longstatus_print_other_header(struct wt_status *s,
>>>  					     const char *how)
>>>  {
>>>  	const char *c = color(WT_STATUS_HEADER, s);
>>> -	status_printf_ln(s, c, "%s:", what);
>>> +	status_printf_ln(s, c, "%s", what);
>>
>> I.e. this one is better handled by
>>
>> 	status_printf_ln(s, c, _("%s:"), what);
>>
>> as _(...) in C-locale is original-language centric, where we want
>> the label to be <phrase> immediately followed by a colon.  And that
>> allows French translation to have nbsp before the colon.
>
> In this case I think the change as suggested is better, translators get
> zero context from "%s:", whereas "Untracked files:" being status output
> is immediately obvious.

It is unclear if you read the original (and discussion so far).

I understand that Julien wants to turn "%s:" to have nonbreaking
whitespace before the colon.  It does not matter what label we are
using (it can be "Ignored files").  I took it that the patch is
addressing "git status" output but the general thrust is in Julien's
translation, all "label-string followed by colon" should become "the
string followed by nonbreaking whitespace followed by colon".

Moving the colon to the label string is backwards, isn't it?  If the
presentation form accepted in the C-locale, i.e. "%s:", needs to be
localized in Julien's translation to "%s :", shouldn't the "%s:"
that defines the presentation be what is marked for translation?

> His commit message also doesn't mention it, but for existing "headings"
> we already do this, e.g.:
>
>     status_printf_ln(s, c, _("Changes to be committed:"));
>     status_printf_ln(s, c, _("Changes not staged for commit:"));

That's another arugment to translate _("%s:") once for the language,
I would think.

  reply	other threads:[~2022-04-12 16:34 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-04-11  7:02 [PATCH] Make a colon translatable Julien Palard
2022-04-11 19:29 ` Junio C Hamano
2022-04-12  7:30   ` Julien Palard
2022-04-12 16:26     ` Junio C Hamano
2022-04-12  8:03   ` Ævar Arnfjörð Bjarmason
2022-04-12 16:32     ` Junio C Hamano [this message]
2022-04-13 13:11       ` Jean-Noël Avila
2022-04-13 16:48         ` Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: http://vger.kernel.org/majordomo-info.html

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=xmqq35iicle2.fsf@gitster.g \
    --to=gitster@pobox.com \
    --cc=avarab@gmail.com \
    --cc=flashcode@flashtux.org \
    --cc=git@vger.kernel.org \
    --cc=jn.avila@free.fr \
    --cc=julien@palard.fr \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this public inbox

	https://80x24.org/mirrors/git.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).