From: Junio C Hamano <gitster@pobox.com>
To: "René Scharfe" <rene.scharfe@lsrfire.ath.cx>
Cc: Git Mailing List <git@vger.kernel.org>
Subject: Re: [PATCH] log --format: document %w
Date: Sun, 22 Nov 2009 16:06:07 -0800 [thread overview]
Message-ID: <7vtywmayvk.fsf@alter.siamese.dyndns.org> (raw)
In-Reply-To: <4B09CD5A.4070401@lsrfire.ath.cx> ("René Scharfe"'s message of "Mon\, 23 Nov 2009 00\:46\:34 +0100")
René Scharfe <rene.scharfe@lsrfire.ath.cx> writes:
> I think utf8_width() is too generic for that; we shouldn't teach it terminal
> control details.
I agree that the function whose purpose is to compute display width should
not be called utf8_width().
The outside caller of utf8_width() in diff.c uses it to truncate the
function name hint on the hunk header line at character boundary. The
input shouldn't have color escapes _we_ add (it might contain such
sequences from the user data, though), so I agree that we shouldn't
contaminate this function with color escapes.
> strbuf_add_wrapped_text(); ignoring display mode escape codes in there can be
> justified with its purpose.
Surely, and thanks. The patch looks good.
next prev parent reply other threads:[~2009-11-23 0:06 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-11-22 16:15 [PATCH] log --format: document %w René Scharfe
2009-11-22 17:10 ` Junio C Hamano
2009-11-22 23:46 ` René Scharfe
2009-11-23 0:06 ` Junio C Hamano [this message]
2009-11-23 22:40 ` [PATCH] strbuf_add_wrapped_text(): skip over colour codes René Scharfe
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
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=7vtywmayvk.fsf@alter.siamese.dyndns.org \
--to=gitster@pobox.com \
--cc=git@vger.kernel.org \
--cc=rene.scharfe@lsrfire.ath.cx \
/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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox