Hi Andreas,
On Apr 22, 2010, at 10:57 PM, Andreas Seltenreich wrote:
Hi,
many commands in Emacs that move the point long distances push the
mark
so you can go back using C-u C-<SPC>. org-agenda-goto doesn't do
this,
and I found it a bit annoying that I have to navigate the outline
again
to find back to where the point was before using the Agenda.
Patch attached.
regards,
andreas
diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el
index c68038d..9f35069 100644
--- a/lisp/org-agenda.el
+++ b/lisp/org-agenda.el
@@ -6082,6 +6082,7 @@
(pos (marker-position marker)))
(switch-to-buffer-other-window buffer)
(widen)
+ (push-mark)
(goto-char pos)
(when (org-mode-p)
(org-show-context 'agenda)
I am no sure this is the right thing to do. Because, often you will
show *many* places from the agenda before going back to the buffer.
Org-agenda-goto is called by many other functions like org-agenda-
show, org-agenda-recenter etc.
This might work better:
(defun my-org-agenda ()
(interactive)
(push-mark)
(call-interactively 'org-agenda))
(define-key global-map "\C-ca" 'my-org-agenda)
Maybe you can test this and report back?
- Carsten
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode
- Carsten
_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode