From: Juri Linkov Date: Wed, 15 May 2013 23:14:18 +0000 (+0300) Subject: * lisp/isearch.el (minibuffer-local-isearch-map): Bind "\r" to `exit-minibuffer' X-Git-Tag: emacs-24.3.90~173^2^2~42^2~45^2~387^2~2026^2~229^2~75 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=6d65486d647049cbf33524e261bbd891dd28daba;p=emacs.git * lisp/isearch.el (minibuffer-local-isearch-map): Bind "\r" to `exit-minibuffer' instead of `isearch-nonincremental-exit-minibuffer'. (isearch-edit-string): Remove mention of `isearch-nonincremental-exit-minibuffer' from docstring. (isearch-nonincremental-exit-minibuffer): Mark as obsolete. (isearch-forward-exit-minibuffer) (isearch-reverse-exit-minibuffer): Add docstring. (Bug#13348) * doc/emacs/search.texi (Repeat Isearch): Mention key `RET' to finish editing the string. --- diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog index 1d72ba18860..14e9be8ba84 100644 --- a/doc/emacs/ChangeLog +++ b/doc/emacs/ChangeLog @@ -1,3 +1,8 @@ +2013-05-15 Juri Linkov + + * search.texi (Repeat Isearch): Mention key `RET' to finish + editing the string. (Bug#13348) + 2013-05-14 Glenn Morris * ack.texi (Acknowledgments): Don't mention obsolete sup-mouse.el. diff --git a/doc/emacs/search.texi b/doc/emacs/search.texi index 377264223a5..e146177255e 100644 --- a/doc/emacs/search.texi +++ b/doc/emacs/search.texi @@ -175,7 +175,7 @@ element in the minibuffer, where you can edit it. @kindex M-e @r{(Incremental search)} To edit the current search string in the minibuffer without -replacing it with items from the search ring, type @kbd{M-e}. Type +replacing it with items from the search ring, type @kbd{M-e}. Type @key{RET}, @kbd{C-s} or @kbd{C-r} to finish editing the string and search for it. @node Error in Isearch diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b96d830e807..070d2f1bd37 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,14 @@ +2013-05-15 Juri Linkov + + * isearch.el (minibuffer-local-isearch-map): Bind "\r" to + `exit-minibuffer' instead of + `isearch-nonincremental-exit-minibuffer'. + (isearch-edit-string): Remove mention of + `isearch-nonincremental-exit-minibuffer' from docstring. + (isearch-nonincremental-exit-minibuffer): Mark as obsolete. + (isearch-forward-exit-minibuffer) + (isearch-reverse-exit-minibuffer): Add docstring. (Bug#13348) + 2013-05-15 Stefan Monnier * loadup.el: Just use unversioned DOC. diff --git a/lisp/isearch.el b/lisp/isearch.el index 72a125fcecb..04fd594e7f1 100644 --- a/lisp/isearch.el +++ b/lisp/isearch.el @@ -47,7 +47,7 @@ ;; modify the search string before executing the search. There are ;; three commands to terminate the editing: C-s and C-r exit the ;; minibuffer and search forward and reverse respectively, while C-m -;; exits and does a nonincremental search. +;; exits and searches in the last search direction. ;; Exiting immediately from isearch uses isearch-edit-string instead ;; of nonincremental-search, if search-nonincremental-instead is non-nil. @@ -528,7 +528,7 @@ This is like `describe-bindings', but displays only Isearch keys." (defvar minibuffer-local-isearch-map (let ((map (make-sparse-keymap))) (set-keymap-parent map minibuffer-local-map) - (define-key map "\r" 'isearch-nonincremental-exit-minibuffer) + (define-key map "\r" 'exit-minibuffer) (define-key map "\M-\t" 'isearch-complete-edit) (define-key map "\C-s" 'isearch-forward-exit-minibuffer) (define-key map "\C-r" 'isearch-reverse-exit-minibuffer) @@ -1273,7 +1273,6 @@ You can update the global isearch variables by setting new values to The following additional command keys are active while editing. \\ \\[exit-minibuffer] to resume incremental searching with the edited string. -\\[isearch-nonincremental-exit-minibuffer] to do one nonincremental search. \\[isearch-forward-exit-minibuffer] to resume isearching forward. \\[isearch-reverse-exit-minibuffer] to resume isearching backward. \\[isearch-complete-edit] to complete the search string using the search ring." @@ -1307,13 +1306,18 @@ The following additional command keys are active while editing. (interactive) (setq isearch-nonincremental t) (exit-minibuffer)) +;; Changing the value of `isearch-nonincremental' has no effect here, +;; because `isearch-edit-string' ignores this change. Thus marked as obsolete. +(make-obsolete 'isearch-nonincremental-exit-minibuffer 'exit-minibuffer "24.4") (defun isearch-forward-exit-minibuffer () + "Resume isearching forward from the minibuffer that edits the search string." (interactive) (setq isearch-new-forward t) (exit-minibuffer)) (defun isearch-reverse-exit-minibuffer () + "Resume isearching backward from the minibuffer that edits the search string." (interactive) (setq isearch-new-forward nil) (exit-minibuffer))