GNU bug report logs - #13718
prevent hl-line from overriding highlight-mode

Previous Next

Package: emacs;

Reported by: Fei <fei.yuanbw <at> gmail.com>

Date: Fri, 15 Feb 2013 05:33:02 UTC

Severity: normal

Full log


View this message in rfc822 format

From: Fei <fei.yuanbw <at> gmail.com>
To: Stefan Monnier <monnier <at> iro.umontreal.ca>, Drew Adams <drew.adams <at> oracle.com>
Cc: 13718 <at> debbugs.gnu.org
Subject: bug#13718: [patch] prevents hl-line from overriding highlight-mode
Date: Fri, 15 Feb 2013 11:15:10 -0500
> hl-line seems to leave its overlay's priority unspecified (good!), which
> means that it should take precedence over overlays which are larger
> (e.g. span multiple lines) while smaller overlays within the current
> line should take precedence over it.
>
> Can you describe your particular case?  What are the overlays that
> "disappear", what do they cover, and why do you think they should not
> "disappear" like that?

That's actually a reasonable alternative to my hard-coded solution,
but the problem is that it doesn't seem to work in every case: when I
open a file that has syntax highlighting (e.g. Bash or Python) and
then use highlight-phrase/regexp, the global-hl-line will have higher
priority than the highlight, no matter what the size of the highlight
is.  If I do the same thing in text-mode, the problem does not occur.
(This was tested on 24.2.1-i386-mingw-nt6.1.7601  without any custom
configuration.)

> The priority here should be a user option, or at least a defvar that a user can
> tweak.  Likewise, for other overlay priorities in Emacs.

That's fine too, as long as it can be changed without directly messing
with the internals.  Currently there is no such variable available for
either hl-line or any of the highlights.




This bug report was last modified 1 year and 154 days ago.

Previous Next


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