GNU bug report logs - #13480
24.3.50; `C-w' from Isearch should translate newlines to spaces

Previous Next

Package: emacs;

Reported by: Dani Moncayo <dmoncayo <at> gmail.com>

Date: Thu, 17 Jan 2013 20:41:02 UTC

Severity: normal

Tags: moreinfo

Found in version 24.3.50

Done: Lars Ingebrigtsen <larsi <at> gnus.org>

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: Dani Moncayo <dmoncayo <at> gmail.com>
To: Juri Linkov <juri <at> jurta.org>
Cc: 13480 <at> debbugs.gnu.org
Subject: bug#13480: 24.3.50; `C-w' from Isearch should translate newlines to spaces
Date: Sat, 19 Jan 2013 11:40:14 +0100
>> Well, OTOH it makes a lot of sense to think of the text displayed in
>> the echo area (during Isearch) not necessarily as the raw search
>> string, but as its "canonical form", according to the current matching
>> behavior (which the user should be able to alter on-the-fly).
>>
>> Definitely that would be a nice behavior, and not only for the laxity
>> in whitespace matching, but also in other ones discussed recently like
>> those related to accented letters.
>
> `isearch-yank-string' already downcases the yanked upper case string
> to lower case, so it's possible to do the same with lax spaces and
> accented letters.

Yes, but I see that currently the conversion to lowercase is
destructive, i.e., the original text supplied by the user is lost.
For example, if I have "Hello" in the kill ring and do `C-s C-y M-s
c', obviously I'd like to be searching for "Hello" case-sensitively,
but currently I end up searching (case-sensitively) for "hello".
That's wrong, IMO.

I propose to:
1. Store in one variable the "raw" (untouched) search string, as
supplied by the user.
2. Store in another variable (or define a function to get) the
"canonical" search string, based on the raw search string and the
"laxities" enabled at that moment for the search algorithm (related to
whitespace, case-sensitivity, accents, etc).
3. Display the canonical search string in the echo area and use it
also in the search algorithm.

-- 
Dani Moncayo




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

Previous Next


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