* Footnotes in headings results in strange entries in the table of contens of the latex -> pdf export
@ 2010-02-19 14:40 Geralt
2010-02-20 13:39 ` Geralt
0 siblings, 1 reply; 3+ messages in thread
From: Geralt @ 2010-02-19 14:40 UTC (permalink / raw)
To: emacs-orgmode
Hi,
if I put a footnote in a heading and export to pdf via C-c C-e d the
table of contents entry for that heading is garbled. As an example
consider the following minimal org-file:
* This is a simple heading [fn:1]
* Footnotes
[fn:1] A footnote
And here's what I get in the pdf (copy 'n pasted from evince, so it's
not pretty but still readable):
test
19 February 2010
Contents
1section.1
1
1 This is a simple heading
1
A footnote
As you can see the entry in the table of contents does not name the
heading but "1section.1". I'm using Emacs 23.1 and the Org-mode
version shipped with it. Is there a way to fix that?
Thanks,
Geralt.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Footnotes in headings results in strange entries in the table of contens of the latex -> pdf export
2010-02-19 14:40 Footnotes in headings results in strange entries in the table of contens of the latex -> pdf export Geralt
@ 2010-02-20 13:39 ` Geralt
2010-02-23 6:31 ` Carsten Dominik
0 siblings, 1 reply; 3+ messages in thread
From: Geralt @ 2010-02-20 13:39 UTC (permalink / raw)
To: emacs-orgmode
Hi,
I tracked down the problem to latex itself, the generated code looks like this:
\section{This is a simple heading \footnote{A footnote }}
\label{sec-1}
But to get a correct table of contents entry when a section title
contains a footnote it should look like this:
\section[This is a simple heading]{This is a simple heading
\footnote{A footnote }}
\label{sec-1}
The solution was not found by me, I took it from
http://www.mathlinks.ro/Forum/viewtopic.php?t=243820
But I don't want to edit the tex-file manually, how can I fix the
renderer? I looked into it but I don't really understand how the
export (and the latex backend) do their work.
Geralt.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: Re: Footnotes in headings results in strange entries in the table of contens of the latex -> pdf export
2010-02-20 13:39 ` Geralt
@ 2010-02-23 6:31 ` Carsten Dominik
0 siblings, 0 replies; 3+ messages in thread
From: Carsten Dominik @ 2010-02-23 6:31 UTC (permalink / raw)
To: Geralt; +Cc: emacs-orgmode
Hi Gerald,
the LaTeX exporter does indeed have some problems with footnotes in
headlines.
I have now fixed it so that the footnote will be preceded by \protect,
which already makes things nicer. However, to use the format you
propose (which is good LaTeX), Org would have to know which macros
exactly work like that. For example, headlines from Org-mode
sometimes get transformed into \item blocks, where an optional
argument would have completely different effects.
A way out for you would be to add a function to `org-export-latex-
final-hook' which would go through, find and fix the corresponding
headlines.
If you make a good solutions, please share it - I might want to use it
in Org after all.
- Carsten
On Feb 20, 2010, at 2:39 PM, Geralt wrote:
> Hi,
>
> I tracked down the problem to latex itself, the generated code looks
> like this:
> \section{This is a simple heading \footnote{A footnote }}
> \label{sec-1}
>
> But to get a correct table of contents entry when a section title
> contains a footnote it should look like this:
>
> \section[This is a simple heading]{This is a simple heading
> \footnote{A footnote }}
> \label{sec-1}
>
>
> The solution was not found by me, I took it from
> http://www.mathlinks.ro/Forum/viewtopic.php?t=243820
>
>
>
> But I don't want to edit the tex-file manually, how can I fix the
> renderer? I looked into it but I don't really understand how the
> export (and the latex backend) do their work.
>
>
>
> Geralt.
>
>
> _______________________________________________
> 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
- Carsten
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-02-23 7:29 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-02-19 14:40 Footnotes in headings results in strange entries in the table of contens of the latex -> pdf export Geralt
2010-02-20 13:39 ` Geralt
2010-02-23 6:31 ` Carsten Dominik
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).