all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Dani Moncayo <dmoncayo@gmail.com>
To: Juri Linkov <juri@jurta.org>
Cc: 13480@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	[thread overview]
Message-ID: <CAH8Pv0h_9eq7m-Yhfqvaz=O4N09NDO=W5OZS4QXHJxKi+Lp5cQ@mail.gmail.com> (raw)
In-Reply-To: <87obgl5vuz.fsf@mail.jurta.org>

>> 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





  reply	other threads:[~2013-01-19 10:40 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-01-17 20:39 bug#13480: 24.3.50; `C-w' from Isearch should translate newlines to spaces Dani Moncayo
2013-01-17 21:27 ` Juri Linkov
2013-01-17 23:10   ` Dani Moncayo
2013-01-17 23:54     ` Dani Moncayo
2013-01-18 21:59       ` Juri Linkov
2013-01-19  8:05         ` Dani Moncayo
2013-01-19  9:56           ` Dani Moncayo
2013-01-19 10:07             ` Juri Linkov
2013-01-19 10:40               ` Dani Moncayo [this message]
2013-01-19 10:57                 ` Juri Linkov
2013-01-19 12:11                   ` Dani Moncayo
2013-01-19 15:45                     ` Drew Adams
2013-01-19 15:43                   ` Drew Adams
2013-01-19 17:20                     ` Stefan Monnier
2013-01-19 23:30                       ` Juri Linkov
2013-01-20  9:41                         ` Dani Moncayo
2013-01-20 12:27                           ` Dani Moncayo
2022-04-22 12:28                         ` Lars Ingebrigtsen
2022-04-24 15:46                           ` Juri Linkov
2022-04-25  7:26                             ` Lars Ingebrigtsen
2013-01-19 15:01             ` Drew Adams
2013-01-19  9:59           ` Juri Linkov
2013-08-03 17:09 ` Dani Moncayo

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to='CAH8Pv0h_9eq7m-Yhfqvaz=O4N09NDO=W5OZS4QXHJxKi+Lp5cQ@mail.gmail.com' \
    --to=dmoncayo@gmail.com \
    --cc=13480@debbugs.gnu.org \
    --cc=juri@jurta.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.