* FW: pop-tag-mark - shouldn't it use pop-to-buffer insteadofswitch-to-buffer?
@ 2008-03-09 16:43 Drew Adams
0 siblings, 0 replies; only message in thread
From: Drew Adams @ 2008-03-09 16:43 UTC (permalink / raw)
To: Emacs-Devel
Resending.
----
From: Drew Adams Sent: Tuesday, February 12, 2008 11:18 PM
Shouldn't `pop-tag-mark' use `pop-to-buffer' here, instead of
`switch-to-buffer'? Otherwise, if you already have a window/frame open to
the marker's buffer, it doesn't reuse it.
(defun pop-tag-mark ()
"Pop back to where \\[find-tag] was last invoked.
This is distinct from invoking \\[find-tag] with a negative argument
since that pops a stack of markers at which tags were found, not from
where they were found."
(interactive)
(if (ring-empty-p find-tag-marker-ring)
(error "No previous locations for find-tag invocation"))
(let ((marker (ring-remove find-tag-marker-ring 0)))
(switch-to-buffer (or (marker-buffer marker)
(error "The marked buffer has been deleted")))
(goto-char (marker-position marker))
(set-marker marker nil nil)))
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2008-03-09 16:43 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2008-03-09 16:43 FW: pop-tag-mark - shouldn't it use pop-to-buffer insteadofswitch-to-buffer? Drew Adams
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.