[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Isearch halts in commands and macros

From: Juri Linkov
Subject: Re: Isearch halts in commands and macros
Date: Wed, 02 Nov 2005 00:03:38 +0200
User-agent: Gnus/5.110004 (No Gnus v0.4) Emacs/22.0.50 (gnu/linux)

> Only after seeing that a macro with Isearch could work as one would expect
> in GNU Emacs 20 did I determine that the behavior was a reasonable
> expectation to make of Emacs and therefore worthy of sending a bug report.

In Emacs 21 macro termination intentionally causes isearch mode to exit.
You can find in isearch.el the following line that does this:

    (add-hook 'kbd-macro-termination-hook 'isearch-done)

There are other places that check if a keyboard macro is executing,
and don't highlight search strings in this case, etc.

So with the current state, you could write an equivalent Lisp code like:

(defun isearch-current-word ()
  (isearch-forward nil 1)

(global-set-key [?\C-.] 'isearch-current-word)

Juri Linkov

reply via email to

[Prev in Thread] Current Thread [Next in Thread]