From: "Drew Adams" <drew.adams@oracle.com>
Cc: Chong Yidong <cyd@stupidchicken.com>, rms@gnu.org, emacs-devel@gnu.org
Subject: RE: search-whitespace-regexp
Date: Sun, 6 Feb 2005 16:28:33 -0800 [thread overview]
Message-ID: <FDELKNEBLPKKDCEBEJCBKEMGCLAA.drew.adams@oracle.com> (raw)
In-Reply-To: <fc339e4a050206151717835d3b@mail.gmail.com>
> > sometimes the actual whitespace matters.
> Right: in *regexp* search.
while people generally expect regexp searches to be a bit fuzzy, they
might expect a non-regexp search to be exact. Since the fuzzy
whitespace matching often "looks" like normal matching (because the
majority of whitespace is in fact a single space), it might take some
time to see what's going on, resulting in some subtle errors.
This is particularly true if one embeds a search inside a keyboard
macro [which I often do].
Plain (incremental) search should be a literal search. Regexp search should
rigorously respect the regexp. People don't expect either to be fuzzy.
The question is "Under what circumstances should typing a space be
interpreted as wanting to search for any amount of whitespace?"
This is unrelated to both plain search and regexp search. You might or might
not want this _input effect_ with either plain or regexp search.
This is akin to word search (as I think someone mentioned). Ultimately, a
word search or a space-means-whitespace search is implemented with a regexp
search - but the point in both cases is to provide a user-friendly way to do
it, instead of requiring users to know about regexps.
By default, neither `C-M-s' nor `C-s' should respect the user-friendly
space-input feature. Or, rather, the default behavior of each should be
determined by a user option - a la case-fold-search. And, regardless of the
value of this option, you should be able to toggle space-means-whitespace
searching from both `C-M-s' and `C-s', via a key sequence.
The question then becomes how to toggle this space-means-whitespace
searching? An obvious candidate is `C-s C-SPC'. (Some will no doubt argue
against this because it means you can't just end a search and set the mark
this way.)
next prev parent reply other threads:[~2005-02-07 0:28 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-02-04 14:12 search-whitespace-regexp Chong Yidong
2005-02-04 14:36 ` search-whitespace-regexp Andreas Schwab
2005-02-04 15:22 ` search-whitespace-regexp Chong Yidong
2005-02-04 15:27 ` search-whitespace-regexp Chong Yidong
2005-02-04 15:17 ` search-whitespace-regexp Stefan Monnier
2005-02-04 15:55 ` search-whitespace-regexp Chong Yidong
2005-02-05 17:39 ` search-whitespace-regexp Richard Stallman
2005-02-06 1:59 ` search-whitespace-regexp Chong Yidong
2005-02-06 12:42 ` search-whitespace-regexp Richard Stallman
2005-02-06 16:21 ` search-whitespace-regexp Stefan Monnier
2005-02-06 22:39 ` search-whitespace-regexp Miles Bader
2005-02-06 22:49 ` search-whitespace-regexp Stefan Monnier
2005-02-06 23:17 ` search-whitespace-regexp Miles Bader
2005-02-07 0:28 ` Drew Adams [this message]
2005-02-07 0:41 ` search-whitespace-regexp Miles Bader
2005-02-07 1:36 ` search-whitespace-regexp Chong Yidong
2005-02-07 4:12 ` search-whitespace-regexp Drew Adams
2005-02-07 9:48 ` search-whitespace-regexp Andreas Schwab
2005-02-07 20:51 ` search-whitespace-regexp Richard Stallman
2005-02-07 20:51 ` search-whitespace-regexp Richard Stallman
2005-02-07 21:07 ` search-whitespace-regexp Stefan Monnier
2005-02-08 0:01 ` search-whitespace-regexp Miles Bader
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
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=FDELKNEBLPKKDCEBEJCBKEMGCLAA.drew.adams@oracle.com \
--to=drew.adams@oracle.com \
--cc=cyd@stupidchicken.com \
--cc=emacs-devel@gnu.org \
--cc=rms@gnu.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 public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).