GNU bug report logs - #4344
Highlight escape character sequences in isearch and query-replace

Previous Next

Package: emacs;

Reported by: Juri Linkov <juri <at> jurta.org>

Date: Fri, 4 Sep 2009 21:25:10 UTC

Severity: normal

Done: Juri Linkov <juri <at> jurta.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: help-debbugs <at> gnu.org (Emacs bug Tracking System)
To: Juri Linkov <juri <at> jurta.org>
Subject: bug#4344 closed by Juri Linkov <juri <at> jurta.org> (Re: bug#4344:
 Highlight escape character sequences in isearch and query-replace)
Date: Thu, 10 Sep 2009 01:05:07 +0000
[Message part 1 (text/plain, inline)]
This is an automatic notification regarding your bug report
which was filed against the emacs package:

#4344: Highlight escape character sequences in isearch and query-replace

It has been closed by Juri Linkov <juri <at> jurta.org>.

Their explanation is attached below along with your original report.
If this explanation is unsatisfactory and you have not received a
better one in a separate message then please contact Juri Linkov <juri <at> jurta.org> by
replying to this email.


-- 
4344: http://debbugs.gnu.org/cgi/bugreport.cgi?bug=4344
Emacs Bug Tracking System
Contact help-debbugs <at> gnu.org with problems
[Message part 2 (message/rfc822, inline)]
From: Juri Linkov <juri <at> jurta.org>
To: Stefan Monnier <monnier <at> IRO.UMontreal.CA>
Cc: 4344-done <at> debbugs.gnu.org
Subject: Re: bug#4344: Highlight escape character sequences in isearch and query-replace
Date: Thu, 10 Sep 2009 03:55:55 +0300
>> Normally characters sequences using `^' are displayed in the
>> `escape-glyph' face.  However, in isearch and query-replace that both
>> use `isearch-text-char-description' it is hard to distinguish
>> escape character sequences visually because they are not highlighted.
>> Here is a fix:
>
> Feel free to install it, thanks,

Done.

-- 
Juri Linkov
http://www.jurta.org/emacs/
[Message part 3 (message/rfc822, inline)]
From: Juri Linkov <juri <at> jurta.org>
To: bug-gnu-emacs <at> gnu.org
Subject: Highlight escape character sequences in isearch and query-replace
Date: Sat, 05 Sep 2009 00:14:38 +0300
Normally characters sequences using `^' are displayed in the
`escape-glyph' face.  However, in isearch and query-replace that both
use `isearch-text-char-description' it is hard to distinguish
escape character sequences visually because they are not highlighted.
Here is a fix:

Index: lisp/isearch.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/isearch.el,v
retrieving revision 1.346
diff -u -r1.346 isearch.el
--- lisp/isearch.el	1 Sep 2009 07:24:19 -0000	1.346
+++ lisp/isearch.el	4 Sep 2009 21:12:37 -0000
@@ -2496,8 +2501,8 @@
 
 (defun isearch-text-char-description (c)
   (cond
-   ((< c ?\s) (format "^%c" (+ c 64)))
-   ((= c ?\^?) "^?")
+   ((< c ?\s) (propertize (format "^%c" (+ c 64)) 'face 'escape-glyph))
+   ((= c ?\^?) (propertize "^?" 'face 'escape-glyph))
    (t (char-to-string c))))
 
 ;; General function to unread characters or events.

-- 
Juri Linkov
http://www.jurta.org/emacs/



This bug report was last modified 15 years and 254 days ago.

Previous Next


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