emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] Changes to emacs/lisp/isearch.el


From: Stefan Monnier
Subject: [Emacs-diffs] Changes to emacs/lisp/isearch.el
Date: Mon, 05 Jul 2004 19:41:14 -0400

Index: emacs/lisp/isearch.el
diff -c emacs/lisp/isearch.el:1.231 emacs/lisp/isearch.el:1.232
*** emacs/lisp/isearch.el:1.231 Mon Jul  5 22:41:44 2004
--- emacs/lisp/isearch.el       Mon Jul  5 23:28:42 2004
***************
*** 1,7 ****
  ;;; isearch.el --- incremental search minor mode
  
! ;; Copyright (C) 1992, 93, 94, 95, 96, 97, 1999, 2000, 01, 2003, 2004
! ;;   Free Software Foundation, Inc.
  
  ;; Author: Daniel LaLiberte <address@hidden>
  ;; Maintainer: FSF
--- 1,7 ----
  ;;; isearch.el --- incremental search minor mode
  
! ;; Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1999,
! ;;   2000, 2001, 2003, 2004  Free Software Foundation, Inc.
  
  ;; Author: Daniel LaLiberte <address@hidden>
  ;; Maintainer: FSF
***************
*** 59,65 ****
  
  ;; TODO
  ;; - Integrate the emacs 19 generalized command history.
- ;; - Think about incorporating query-replace.
  ;; - Hooks and options for failed search.
  
  ;;; Change Log:
--- 59,64 ----
***************
*** 338,345 ****
      (define-key map "\M-r" 'isearch-toggle-regexp)
      (define-key map "\M-e" 'isearch-edit-string)
  
!     (define-key map (kbd   "M-%") 'isearch-query-replace)
!     (define-key map (kbd "C-M-%") 'isearch-query-replace-regexp)
  
      map)
    "Keymap for `isearch-mode'.")
--- 337,344 ----
      (define-key map "\M-r" 'isearch-toggle-regexp)
      (define-key map "\M-e" 'isearch-edit-string)
  
!     (define-key map [?\M-%] 'isearch-query-replace)
!     (define-key map [?\C-\M-%] 'isearch-query-replace-regexp)
  
      map)
    "Keymap for `isearch-mode'.")
***************
*** 1062,1075 ****
  (defun isearch-query-replace ()
    "Start query-replace with string to replace from last search string."
    (interactive)
!   (let ((query-replace-interactive t)
!         (case-fold-search isearch-case-fold-search))
!     ;; Put search string into the right ring
!     (setq isearch-regexp nil)
      (isearch-done)
      (isearch-clean-overlays)
      (and isearch-forward isearch-other-end (goto-char isearch-other-end))
!     (call-interactively 'query-replace)))
  
  (defun isearch-query-replace-regexp ()
    "Start query-replace-regexp with string to replace from last search string."
--- 1061,1075 ----
  (defun isearch-query-replace ()
    "Start query-replace with string to replace from last search string."
    (interactive)
!   (barf-if-buffer-read-only)
!   (let ((case-fold-search isearch-case-fold-search))
      (isearch-done)
      (isearch-clean-overlays)
      (and isearch-forward isearch-other-end (goto-char isearch-other-end))
!     (perform-replace
!      isearch-string
!      (query-replace-read-to isearch-string "Query replace" isearch-regexp)
!      t isearch-regexp isearch-word)))
  
  (defun isearch-query-replace-regexp ()
    "Start query-replace-regexp with string to replace from last search string."
***************
*** 2380,2384 ****
        isearch-case-fold-search case-fold)
    (isearch-search))
  
! ;;; arch-tag: 74850515-f7d8-43a6-8a2c-ca90a4c1e675
  ;;; isearch.el ends here
--- 2380,2384 ----
        isearch-case-fold-search case-fold)
    (isearch-search))
  
! ;; arch-tag: 74850515-f7d8-43a6-8a2c-ca90a4c1e675
  ;;; isearch.el ends here




reply via email to

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