emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [O] Opening an Org file slowed down


From: Nicolas Goaziou
Subject: Re: [O] Opening an Org file slowed down
Date: Sun, 24 Nov 2013 17:25:56 +0100

Hello,

Michael Brand <address@hidden> writes:

> First, I have an understanding question:
>
> I tried to find where org-mode-hook is called within the function
> org-mode but could not see something similar to the expected
> "(run-hooks 'org-mode-hook)". So I added 'backtrace to the
> org-mode-hook but don't understand it either:
>
>     (backtrace)
>       backtrace()
>       run-hooks(change-major-mode-after-body-hook text-mode-hook
> outline-mode-hook org-mode-hook)
>       apply(run-hooks (change-major-mode-after-body-hook
> text-mode-hook outline-mode-hook org-mode-hook))
>       run-mode-hooks(org-mode-hook)
>       org-mode()
>       [...]
>
> I see the expected "run-mode-hooks(org-mode-hook)" in this backtrace
> but where is the corresponding form in the function org-mode?

It is implied by `define-derived-mode'.

> Second, I guess it is not necessary to implement something like
> org-mode-early-hook but I could not find yet an existing hook. Which
> hook would you recommend for inserting the leading stars?

I didn't look at your code, but can't you `defadvice' `org-mode'?


Regards,

-- 
Nicolas Goaziou



reply via email to

[Prev in Thread] Current Thread [Next in Thread]