[Top][All Lists]

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

Re: [O] accessing org-lowest-priority in .emacs

From: Nick Dokos
Subject: Re: [O] accessing org-lowest-priority in .emacs
Date: Thu, 16 Jun 2011 09:39:06 -0400

Filippo A. Salustri <address@hidden> wrote:

> I've got code of this form in my Preferences.el (aquamacs-speak for .emacs):
> (defvar fas/org-some-variable
>   (/ 10 (* 1000 (- org-lowest-priority org-highest-priority))))
> But org-lowest-priority & org-highest-priority aren't defined at that
> point in Preferences.el.  I need to defer the calculation till org is
> running.

You just need to defer it until org is loaded: just put it after the
(require 'org-install). If you are depending on an autoloaded function
to be called in order to load org, you can just (require 'org) at some
place in Preferences.el and put the defvar after it. Or you can
initialize it in a hook - org-load-hook is the one to use here:

(add-to-list 'org-load-hook 
               (lambda ()
                (setq  fas/org-some-variable
                       (/ 10 (* 1000 (- org-lowest-priority 


reply via email to

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