all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Continuing after an interactive command?
@ 2013-05-28  2:24 gentsquash
  2013-05-28  7:39 ` Thien-Thi Nguyen
       [not found] ` <mailman.502.1369726605.22516.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 3+ messages in thread
From: gentsquash @ 2013-05-28  2:24 UTC (permalink / raw)
  To: help-gnu-emacs

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


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

end of thread, other threads:[~2013-05-29  2:34 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-05-28  2:24 Continuing after an interactive command? gentsquash
2013-05-28  7:39 ` Thien-Thi Nguyen
     [not found] ` <mailman.502.1369726605.22516.help-gnu-emacs@gnu.org>
2013-05-29  2:34   ` gentsquash

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.