Pedro Andres Aranda Gutierrez <paaguti@gmail.com> writes:
> Attached is a patch that fixes adding an unnumbered section to the TOC with
> test cases. You will need to add the Title you want to appear in the ToC in
> :ALT_TITLE: I'm looking at a new property to copy the section title.
> Something like
> :ALT_TITLE_COPY: t
> But I'm open to suggestions.
Not sure.
If we look into the manual, here is what it says:
13.3 Table of Contents
...
Org includes both numbered and unnumbered headlines in the table of
contents(1). If you need to exclude an unnumbered headline, along with
all its children, set the ‘UNNUMBERED’ property to ‘notoc’ value.
...
(1) At the moment, some export backends do not obey this
specification. For example, LaTeX export excludes every unnumbered
headline from the table of contents.
But this happens because of the way LaTeX works...
So, ox-latex is technically not right when it ignores unnumbered
headings in TOC.
The basis is there... we might need to rewrite (org-latex-headings) a lot - I fear.
We might consider changing the current defaults to be consistent with
the rest of export backends + a defcustom/export option to allow users
fall back to historic defaults.
Call them LaTeX-native defaults (sounds better than historic).
BTW, since my patch produces correct LaTeX code vs. the current state, could you please apply it to avoid the error which triggered all this until we get something better.
The documentation would need to modified slightly to
For example, LaTeX export excludes every unnumbered headline from the table of contents, unless you set the 'ALT_TITLE' property to the heading you want to see in the table of contents.
--
Ihor Radchenko // yantar92,
Org mode maintainer,
Learn more about Org mode at <https://orgmode.org/>.
Support Org development at <https://liberapay.com/org-mode>,
or support my work at <https://liberapay.com/yantar92>