emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* heads up: mode hooks not executed for agenda files
@ 2013-01-13 22:30 Eric S Fraga
  2013-01-26 13:25 ` Bastien
  0 siblings, 1 reply; 2+ messages in thread
From: Eric S Fraga @ 2013-01-13 22:30 UTC (permalink / raw)
  To: emacs-orgmode

Hello,

a problem I have had for a long time is that agenda files are 
opened without =org-mode-hook= and =text-mode-hook= being 
processed.  This is a problem because I work within the agenda 
view all the time, writing notes by accessing entries from the 
agenda view.

If I open an org file directly, both hooks are executed just 
fine.  However, if I hit =RET= on an agenda view line, I get put 
into the org file, at the correct point, but without those hooks 
having been executed.  This means that the behaviour is different 
depending on how I ended up in the org file.

This is confusing!
 
The solution is to add the same processing to 
=org-agenda-after-show-hook= as is included in =text-mode=hook= 
and =org-mode=hook=.  This works.  However, it seems clumsy to me.

I just thought I'd highlight this as it took me a while to 
understand why Emacs was doing things differently in org files 
depending on how I got to them. 

Bastien: enjoy your two week break and don't you dare read this 
email before then! ;-)

Thanks,
eric

-- 
: Eric S Fraga, GnuPG: 0xC89193D8FFFCF67D
: in Emacs 24.3.50.1 and Org release_7.9.3a-808-gf94d81

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

end of thread, other threads:[~2013-01-26 13:25 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-13 22:30 heads up: mode hooks not executed for agenda files Eric S Fraga
2013-01-26 13:25 ` Bastien

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