* Applying the same function to all open buffers
@ 2006-11-10 13:56 mads_lindstroem
2006-11-10 15:29 ` Kevin Rodgers
0 siblings, 1 reply; 2+ messages in thread
From: mads_lindstroem @ 2006-11-10 13:56 UTC (permalink / raw)
Hi all
How do I apply the same function to all open buffers?
For example I would like to do a query-replace in all open buffers
like:
for-all-buffers 'query-replace
Greetings
Mads Lindstrøm
^ permalink raw reply [flat|nested] 2+ messages in thread
* Re: Applying the same function to all open buffers
2006-11-10 13:56 Applying the same function to all open buffers mads_lindstroem
@ 2006-11-10 15:29 ` Kevin Rodgers
0 siblings, 0 replies; 2+ messages in thread
From: Kevin Rodgers @ 2006-11-10 15:29 UTC (permalink / raw)
mads_lindstroem@yahoo.dk wrote:
> How do I apply the same function to all open buffers?
(mapc 'same-function (buffer-list))
> For example I would like to do a query-replace in all open buffers
> like:
>
> for-all-buffers 'query-replace
This might work, but there's probably a better way using ibuffer or
somthing:
(mapc (lambda (buffer)
(save-excursion
(switch-to-buffer buffer)
(call-interactively 'query-replace)))
(buffer-list))
--
Kevin
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2006-11-10 15:29 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-11-10 13:56 Applying the same function to all open buffers mads_lindstroem
2006-11-10 15:29 ` Kevin Rodgers
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).