emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Displaying your Org agenda after idle time
@ 2010-03-18  9:30 John Wiegley
  2010-03-18 18:17 ` Jason Dunsmore
  2010-03-21 21:45 ` Ross A. Laird
  0 siblings, 2 replies; 5+ messages in thread
From: John Wiegley @ 2010-03-18  9:30 UTC (permalink / raw)
  To: Org-mode Mode

I have the following snippet in my .emacs file, which I find very useful.  Basically what it does is that if I don't touch my Emacs for 5 minutes, it displays the current agenda.  This keeps my tasks "always in mind" whenever I come back to Emacs after doing something else, whereas before I had a tendency to forget that it was there.

John

(defun jump-to-org-agenda ()
  (interactive)
  (let ((buf (get-buffer "*Org Agenda*"))
	wind)
    (if buf
	(if (setq wind (get-buffer-window buf))
	    (select-window wind)
	  (if (called-interactively-p)
	      (progn
		(select-window (display-buffer buf t t))
		(org-fit-window-to-buffer)
		;; (org-agenda-redo)
		)
	    (with-selected-window (display-buffer buf)
	      (org-fit-window-to-buffer)
	      ;; (org-agenda-redo)
	      )))
      (call-interactively 'org-agenda-list)))
  ;;(let ((buf (get-buffer "*Calendar*")))
  ;;  (unless (get-buffer-window buf)
  ;;    (org-agenda-goto-calendar)))
  )

(run-with-idle-timer 300 t 'jump-to-org-agenda)

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

end of thread, other threads:[~2010-03-23  7:38 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-03-18  9:30 Displaying your Org agenda after idle time John Wiegley
2010-03-18 18:17 ` Jason Dunsmore
2010-03-21 21:45 ` Ross A. Laird
2010-03-23  5:15   ` Alan E. Davis
2010-03-23  7:38     ` Carsten Dominik

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

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).