GNU bug report logs - #54634
29.0.50; Off-by-one highlighting

Previous Next

Package: emacs;

Reported by: Rudolf Adamkovič <salutis <at> me.com>

Date: Wed, 30 Mar 2022 06:37:01 UTC

Severity: minor

Found in version 29.0.50

Full log


Message #25 received at 54634 <at> debbugs.gnu.org (full text, mbox):

From: Rudolf Adamkovič <salutis <at> me.com>
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 54634 <at> debbugs.gnu.org
Subject: Re: bug#54634: 29.0.50; Off-by-one highlighting
Date: Sat, 09 Apr 2022 22:41:09 +0200
Eli Zaretskii <eliz <at> gnu.org> writes:

> If you can suggest a better setting for the priority/priorities of the
> two involved overlays, perhaps we could change the priority only when
> this style of show-paren-mode is used, and that would be an okay
> solution.

Eli, thank you for the reply!

In the reproduction case above, I would expect the active region highlight to
take precedence over the parenthesized expression highlight.  Effectively, the
active region highlight should cover the entire expression, including both of
its parentheses, rendering the expression highlight itself hidden.

I see two issues in play here:

(1) The priority, when using this particular style, does not make much sense.
For myself, I work around the issue as follows:

> Highlight parenthesized expressions with lower priority to avoid covering
> more important highlights, such as the active region highlight provided by
> the Transient Mark mode.
> 
> #+BEGIN_SRC emacs-lisp
> (setq show-paren-priority 0)
> #+END_SRC

(2) If we decide to fix the priority, then that uncovers the off-by-one active
region highlight bug that I reported.  I have waited for a couple of months
with reporting the bug to become sure that this configuration makes sense and
the highlight continues to confuse me.  It does and it does.

Rudy
-- 
"Be especially critical of any statement following the word
'obviously.'"
-- Anna Pell Wheeler, 1883-1966

Rudolf Adamkovič <salutis <at> me.com> [he/him]
Studenohorská 25
84103 Bratislava
Slovakia




This bug report was last modified 3 years and 98 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.