[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Continuing after an interactive command?
From: |
gentsquash |
Subject: |
Continuing after an interactive command? |
Date: |
Mon, 27 May 2013 19:24:54 -0700 (PDT) |
User-agent: |
G2/1.0 |
How can I define a function which contains a command that
I interact with, which then continues?
I seek a function like the following, executed when in a
buffer:
(defun foo ()
(ns-narrow-to-region 100 200)
(goto-char (point-min))
(dired-jump)
;; This next cmd interacts with the user.
(dired-do-query-replace-regexp FROM TO)
;; If the above cmd terminates normally, I'd like these
;; to be executed:
(dired-find-file)
(ns-widen)
)
Typically, when the `dired-do-query-replace-regexp' runs,
I'll hit "!" to have it do all the replacements. I then
would like to end up in the buffer, widened.
However, in the above function, when the
`dired-do-query-replace-regexp' terminates, it seems to
terminate `foo' as well.
--Jonathan
- Continuing after an interactive command?,
gentsquash <=