all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* isearch-yank-word-or-char
@ 2007-07-30  0:23 Drew Adams
  2007-07-30  0:33 ` isearch-yank-word-or-char Drew Adams
  2007-07-30  5:34 ` isearch-yank-word-or-char Mathias Dahl
  0 siblings, 2 replies; 4+ messages in thread
From: Drew Adams @ 2007-07-30  0:23 UTC (permalink / raw)
  To: Emacs-Devel

In Emacs 22, C-w in Isearch is "smarter" than I would like it to be - or
else I haven't yet learned how to use it (suggestions welcome). The doc says
only that "The decision, whether to copy a character or a word, is
heuristic." Does that mean that a user has no control over the behavior?

    (or (eq foo '(bar . toto

Previously, with point at bol here, C-s plus 5 C-w's would select everything
through toto. Now, it takes 14 C-w's to do the same thing! That's a real
nuisance. What am I missing? Is there some way to get it to collect multiple
non-word characters such as spaces, parens, and period with a single
keystroke when it is in "word" mode?

So far, I prefer the pre-Emacs 22 behavior of Isearch, but I'm sure that
others tried this out before the release and found it to be an improvement
(TRT). I'm hoping that someone will point out why the new behavior is better
and how to take advantage of it. Thanks in advance; this is driving me nuts.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* RE: isearch-yank-word-or-char
  2007-07-30  0:23 isearch-yank-word-or-char Drew Adams
@ 2007-07-30  0:33 ` Drew Adams
  2007-07-30  5:34 ` isearch-yank-word-or-char Mathias Dahl
  1 sibling, 0 replies; 4+ messages in thread
From: Drew Adams @ 2007-07-30  0:33 UTC (permalink / raw)
  To: Emacs-Devel

I said:

> So far, I prefer the pre-Emacs 22 behavior of Isearch, 

I meant wrt C-s C-w.

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: isearch-yank-word-or-char
  2007-07-30  0:23 isearch-yank-word-or-char Drew Adams
  2007-07-30  0:33 ` isearch-yank-word-or-char Drew Adams
@ 2007-07-30  5:34 ` Mathias Dahl
  2007-08-01 16:47   ` isearch-yank-word-or-char Juri Linkov
  1 sibling, 1 reply; 4+ messages in thread
From: Mathias Dahl @ 2007-07-30  5:34 UTC (permalink / raw)
  To: Drew Adams; +Cc: Emacs-Devel

> So far, I prefer the pre-Emacs 22 behavior of Isearch, but I'm sure that
> others tried this out before the release and found it to be an improvement
> (TRT). I'm hoping that someone will point out why the new behavior is better
> and how to take advantage of it. Thanks in advance; this is driving me nuts.

FWIW, I like the new behaviour, it gives me more control. I mostly use
the C-w binding when I want to search for a procedure name, and
sometimes it ends with a number of underscores, like this:

PROCEDURE Do_The_Stuff___ (foo IN NUMBER) IS

Previously, having point at D, when using C-w, using it three times
to "eat" the last f in "Stuff", if typed once more it ate I think all the
way to foo. Now three extra C-w eats all the underscores, which is
what I want, most of the times. I have never thought about the new
behaviour as being cumbersome.

/Mathias

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: isearch-yank-word-or-char
  2007-07-30  5:34 ` isearch-yank-word-or-char Mathias Dahl
@ 2007-08-01 16:47   ` Juri Linkov
  0 siblings, 0 replies; 4+ messages in thread
From: Juri Linkov @ 2007-08-01 16:47 UTC (permalink / raw)
  To: Mathias Dahl; +Cc: Drew Adams, emacs-devel

> FWIW, I like the new behaviour, it gives me more control. I mostly use
> the C-w binding when I want to search for a procedure name, and
> sometimes it ends with a number of underscores, like this:
>
> PROCEDURE Do_The_Stuff___ (foo IN NUMBER) IS
>
> Previously, having point at D, when using C-w, using it three times
> to "eat" the last f in "Stuff", if typed once more it ate I think all the
> way to foo. Now three extra C-w eats all the underscores, which is
> what I want, most of the times. I have never thought about the new
> behaviour as being cumbersome.

Now the need to collect non-word characters by C-w is mitigated by two
keybindings C-M-w and C-M-y that removes/adds one character.  So with
C-w overshoot you can remove or add more characters with these keys.

And note that even with new heuristic, C-w doesn't do what you want.
According to your description you want to put the whole identifier to the
search string, so you probably wish a single key like C-M-f to grab the
whole expression.

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

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2007-08-01 16:47 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-07-30  0:23 isearch-yank-word-or-char Drew Adams
2007-07-30  0:33 ` isearch-yank-word-or-char Drew Adams
2007-07-30  5:34 ` isearch-yank-word-or-char Mathias Dahl
2007-08-01 16:47   ` isearch-yank-word-or-char Juri Linkov

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.