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: 13718 <at> debbugs.gnu.org
Subject: bug#13718: [patch] prevents hl-line from overriding highlight-mode
Date: Thu, 14 Feb 2013 23:28:37 -0500
Hello,

I found that the overlays in highlight-mode do not override the
overlays from global-hl-line-mode, causing them to disappear on the
currently active line.  The solution I found was to edit hi-lock.el to
increase the priority of the overlay, as outlined in this patch:

--- hi-lock.el 2012-08-28 19:40:24.000000000 -0400
+++ hi-lock.el 2013-02-14 12:57:56.715031100 -0500
@@ -591,6 +591,7 @@
             (goto-char search-start)
             (while (re-search-forward regexp search-end t)
               (let ((overlay (make-overlay (match-beginning 0) (match-end 0))))
+                (overlay-put overlay 'priority 1)
                 (overlay-put overlay 'hi-lock-overlay t)
                 (overlay-put overlay 'hi-lock-overlay-regexp serial)
                 (overlay-put overlay 'face face))

My Emacs version is: 24.2.1 (i386-mingw-nt6.1.7601) 2012-08-28 on MARVIN

Thanks,
Fei




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.