all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Request for feedback about LaTeX setup changes
@ 2010-04-05 13:13 Carsten Dominik
  2010-04-05 18:28 ` Mark Elston
  2010-04-07 14:01 ` Giovanni Ridolfi
  0 siblings, 2 replies; 5+ messages in thread
From: Carsten Dominik @ 2010-04-05 13:13 UTC (permalink / raw)
  To: Org-Mode List

Dear all,

I need some feedback.

Here is new new section from the list of changes, about the LaTeX  
setup.  I would like to hear honest answers if I have gone completely  
crazy, of if this actually makes any sense.

Thanks.

- Carsten
--------------------------------------------------------------------------
       Changes to the intended use of =org-export-latex-classes=
       =========================================================

So far this variable has been used to specify the complete header
of the LaTeX document, including all the =\usepackage= calls
necessary for the document.  This setup makes it difficult to
maintain the list of packages that Org itself would like to call,
for example for the special symbol support it needs.  Each time I
have to add a package, I have to ask people to revise the
configuration of this variable.  In this release, I have tried to
fix this.

First of all, you can *opt out of this change* in the following
way: You can say: /I want to have full control over headers, and
I will take responsibility to include the packages Org needs/.
If that is what you want, add this to your configuration and skip
the rest of this section (except maybe for the description of the
=[EXTRA]= place holder):


   (setq org-export-latex-default-packages-alist nil
         org-export-latex-packages-alist nil)

/Continue to read here if you want to go along with the modified
setup./

There are now two variables that should be used to list the LaTeX
packages that need to be included in all classes.  The header
definition in =org-export-latex-classes= should then not contain
the corresponding =\usepackage= calls (see below).

The two new variables are:

1. =org-export-latex-default-packages-alist= :: This is the
      variable where Org-mode itself puts the packages it needs.
      Normally you should not change this variable.  The only
      reason to change it anyway is when one of these packages
      causes a conflict with another package you want to use.
      Then you can remove that packages and hope that you are not
      using Org-mode functionality that needs it.

2. =org-export-latex-packages-alist= :: This is the variable
      where you can put the packages that you'd like to use across
      all classes.  For example, I am putting =amsmath= and =tikz=
      here, because I always want to have them.

The sequence how these customizations will show up in the LaTeX
document are:
1. Header from =org-export-latex-classes=
2. =org-export-latex-default-packages-alist=
3. =org-export-latex-packages-alist=
4. Buffer-specific things set with =#+LaTeX_HEADER:=

If you want more control about which segment is placed where, or
if you want, for a specific class, have full control over the
header and exclude some of the automatic building blocks, you can
put the following macro-like place holders into the header:


   [DEFAULT-PACKAGES]      \usepackage statements for default packages
   [NO-DEFAULT-PACKAGES]   do not include any of the default packages
   [PACKAGES]              \usepackage statements for packages
   [NO-PACKAGES]           do not include the packages
   [EXTRA]                 the stuff from #+LaTeX_HEADER
   [NO-EXTRA]              do not include #+LaTeX_HEADER stuff

If you have currently customized =org-export-latex-classes=, you
should revise that customization and remove any package calls that
are covered by =org-export-latex-default-packages-alist=.  This
applies to the following packages:

- inputenc
- fontenc
- graphicx
- longtable
- float
- wrapfig
- soul
- t1enc
- textcomp
- marvosym
- wasysym
- latexsym
- amssymb
- hyperref

If one of these packages creates a conflict with another package
you are using, you can remove it from
=org-export-latex-default-packages-alist=.  But then you risk
that some of the advertised export features of Org will not work
properly.

You can also consider moving packages that you use in all classes
to =org-export-latex-packages-alist=.  If necessary, put the
place holders so that the packages get loaded in the right
sequence.  As said above, for backward compatibility, if you omit
the place holders, all the variables will dump their content at
the end of the header.

Damn, this has become more complex than I wanted it to be.  I
hope that in practice, this will not be complicated at all.

^ permalink raw reply	[flat|nested] 5+ messages in thread
* Re: Request for feedback about LaTeX setup changes
@ 2010-04-07 17:04 Aaron Hammitt
  2010-04-07 22:33 ` Carsten Dominik
  0 siblings, 1 reply; 5+ messages in thread
From: Aaron Hammitt @ 2010-04-07 17:04 UTC (permalink / raw)
  To: Emacs-orgmode


[-- Attachment #1.1: Type: text/plain, Size: 1079 bytes --]

I like the fact that I don't have to clutter org-export-latex-classes with
so many options. I also like org-export-latex-packages-alist better than
what I was doing previously with org-export-latex-append-header.

The downside is that I had some conflicts between the org default packages
(with either wasysym or latexsym, but now I don't recall which one) and
other packages I import in all my documents. Also, I like to use the
hyperref package with colorlinks=True and my own linkcolor, so I had to
modify org-export-latex-default-packages-alist anyway. Now I'm in the
position of still having to manually update
org-export-latex-default-packages-alist if you change the packages that are
required by orgmode in the future.

Despite the initial work of figuring out where the conflicts were arising
from (after first upgrading to 6.35) and having to download some of the
default packages, I do like the new setup. I can't think of a better
solution; everything I can think of that would solve one problem would just
lead to another. And like you said, I can always opt out...

[-- Attachment #1.2: Type: text/html, Size: 1121 bytes --]

[-- Attachment #2: Type: text/plain, Size: 201 bytes --]

_______________________________________________
Emacs-orgmode mailing list
Please use `Reply All' to send replies to the list.
Emacs-orgmode@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-orgmode

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

end of thread, other threads:[~2010-04-07 22:33 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-04-05 13:13 Request for feedback about LaTeX setup changes Carsten Dominik
2010-04-05 18:28 ` Mark Elston
2010-04-07 14:01 ` Giovanni Ridolfi
  -- strict thread matches above, loose matches on Subject: below --
2010-04-07 17:04 Aaron Hammitt
2010-04-07 22:33 ` Carsten Dominik

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.