emacs-orgmode
[Top][All Lists]
Advanced

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

[Orgmode] Re: [BUG] htmlp and latexp


From: Dan Davison
Subject: [Orgmode] Re: [BUG] htmlp and latexp
Date: Wed, 16 Feb 2011 17:11:36 +0000
User-agent: Gnus/5.110011 (No Gnus v0.11) Emacs/24.0.50 (darwin)

Bastien <address@hidden> writes:

> Hi Dan,
>
> Dan Davison <address@hidden> writes:
>
>> I was about to make a temporary fix but I see Bastien's just fixed
>> it. Bastien -- should we give that `backend' variable a name within the
>> org-* namespace (and maybe defvar it in org.el?) so that it is a more
>> respectable way to test for "am I doing export now?"? (This issue just
>> came up in a separate babel thread).
>
> backend is dynamically scoped, so I think there is no need to defvar it
> in org.el -- only in org-*-blocks.el, to avoid compilation warnings.
>
> Let me know if you think otherwise.

Hi Bastien,

I was thinking that if it were defvard in org.el, say as

(defvar org-export-current-backend nil)

then any code could use (null org-export-current-backend) to test
whether org is currently exporting or not. Otherwise, the code has to be
certain that it has been called during export if it is going to access
the variable.

For example, babel code can get called both during interactive
evaluation with C-c C-c, and also during export. It might be helpful for
that code to be able to inspect the value of org-export-current-backend
to see what the current context is.

Dan

>
> But it's a good idea to rename it to org-export-backend.  Can you do it?



reply via email to

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