[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Orgmode] Re: [bug] latex export ignores org-export-latex-default-pa
From: |
Eric S Fraga |
Subject: |
Re: [Orgmode] Re: [bug] latex export ignores org-export-latex-default-packages-alist? |
Date: |
Wed, 26 Jan 2011 16:34:13 +0000 |
User-agent: |
Gnus/5.110011 (No Gnus v0.11) Emacs/24.0.50 (gnu/linux) |
Lawrence Mitchell <address@hidden> writes:
> Eric S Fraga wrote:
>
>> I need to use the amsmath package for a paper I am writing. This
>> conflicts, unfortunately, with the wasysym package which is loaded by
>> default in the org-latex exporter.
>
>> Checking the documentation for org-export-latex-classes, I find:
>
>> ,----
>> | - Calls to \usepackage for all packages mentioned in the variables
>> | `org-export-latex-default-packages-alist' and
>> | `org-export-latex-packages-alist'. Thus, your header definitions should
>> | avoid to also request these packages.
>> `----
>
>> I then checked out the first of these lists and customised it (first, by
>> hand, then by emacs's own customisation method) to turn off the
>> inclusion of wasysym. The value of the variable, upon restarting emacs
>> just to make sure, is:
>
> [...]
>
>> If SNIPPET-FLAG is t, the package also needs to be included when
>> compiling LaTeX snippets into images for inclusion into HTML.
>
> You've set SNIPPET-FLAG to nil for wasysym, but this means
> that wasysym will not be included for compiling latex snippets.
> When producing the whole document it will still be included.
Ahhh, I missed this. Too much reading today and I obviously didn't
concentrate enough on this bit... <blush>
I guess I should have simply deleted that entry from the list now that I
better understand (I think ;-) the settings in this variable.
> To use wasysym along with amsmath, you need to pass the
> "integrals" option to wasysym.
>
> To do this, customize the options list of the wasysym entry to be
> ("integrals" "wasysym" t)
>
> rather than
> ("" "wasysym" t)
>
> This is what I do to use amsmath in Org exports:
>
> | (add-to-list 'org-export-latex-packages-alist '("" "amsmath" t))
> | (setcar (rassoc '("wasysym" t) org-export-latex-default-packages-alist)
> | "integrals")
>
> The latter has to be done after loading org-latex.
Perfect! A bit "magical incantation" at first glance but it makes
sense. I've done this and it works like a charm.
Many thanks.
--
: Eric S Fraga (GnuPG: 0xC89193D8FFFCF67D) in Emacs 24.0.50.1
: using Org-mode version 7.4 (release_7.4.239.g65ac.dirty)