unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
From: gnuist <gnuist@protonmail.com>
To: "help-gnu-emacs@gnu.org" <help-gnu-emacs@gnu.org>
Subject: BUG: ediff-buffers does not consistently show "differences" or "difference regions" within the "active region"
Date: Fri, 19 Jul 2024 19:53:19 +0000	[thread overview]
Message-ID: <h6zlkxvqSlYlEu2zIKRfTxeXnP3lIJo5q15igV0IPDmF_Tb08czVMYW3sorJijKUN9K2jslCKtl-3t5H40gMJL42suaYDgA5csa6NG98k5M=@protonmail.com> (raw)

Hi.

BUG: ediff-buffers does not consistently show "difference regions"

You can try it yourself, 
make two small files A and B, where A has these two lines

a	b
c#d

and B as these two lines

a;b
c;d

and you can put an extra newline after each line and bunch of other lines so that when you run ediff-buffers, it hightlights only one line at a time as an active region.

You will immediately see that TAB is not highlighed in file A in its first line. This is *inconsistent* because in the second case c#d the hash is highlighted as the difference region within active region.

Just to be clear to any other newbie to this command, there are three type of highlighting in question.
1st is the highlighting of the entire active region or "selected difference region" which is the whole line.
2nd is the highlighting of the "differences" of "difference region" which is either TAB, semicolon or HASH, but not a b c d.
3rd is the highlighting of "unselected difference regions" which is usually SAME whitish color in both buffers.

Anyone at FSF/gnu to explain what appears to be such a basic bug staying there for so long?

Interestingly, when the hash in 2nd line is replaced by a TAB after making it active, it remains as a highlighted difference even if you cycle thru all the four highlighting modes.

Here is the punch line. Whatever the definition of highlighting, when I press "i" right after this to get the "status info", it says in the *ediff-message* buffer

Current difference number = 1
Showing regions that differ in white space & line breaks only
Selective browsing by regexp is off

What it means is that TAB and white space is being considered but is not being highlighted properly as HASH is being highlighted as the difference within the active region.

gnuist

P.S. Feel free to reply by email to this particular query if you are hesitant to post a reply.



             reply	other threads:[~2024-07-19 19:53 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-07-19 19:53 gnuist [this message]
2024-07-20  7:04 ` BUG: ediff-buffers does not consistently show "differences" or "difference regions" within the "active region" Michael Heerdegen via Users list for the GNU Emacs text editor

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: https://www.gnu.org/software/emacs/

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

  git send-email \
    --in-reply-to='h6zlkxvqSlYlEu2zIKRfTxeXnP3lIJo5q15igV0IPDmF_Tb08czVMYW3sorJijKUN9K2jslCKtl-3t5H40gMJL42suaYDgA5csa6NG98k5M=@protonmail.com' \
    --to=gnuist@protonmail.com \
    --cc=help-gnu-emacs@gnu.org \
    /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;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).