emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
* Org is exporting to tex an asterisk between "section" and "{"
@ 2016-03-04 19:15 Eduardo Mercovich
  2016-03-04 19:45 ` Eric S Fraga
  0 siblings, 1 reply; 10+ messages in thread
From: Eduardo Mercovich @ 2016-03-04 19:15 UTC (permalink / raw)
  To: emacs-orgmode

Hello evoryone.

Troubleshooting a lack of ToC content in a exported PDF from org, I
found this issue.

Please forgive me if it's inaccurate. But I tried searching the web,
some org and latex lists and my local .emacs configuration and didn't
found anything related, so it must be a local issue or it would have
been reported before. 

Starting with a simple org file like this:

--8<---------------cut here---------------start------------->8---
* Section A, level 1
** Section AA, level 2
Some AA text. 
** Section AB, level 2
Some AB text. 
* Section B, level 1
** Section BA, level 2
Some BA text. 
** Section BB, level 2
Some BB text. 
--8<---------------cut here---------------end--------------->8---

and exporting to latex as latex file (C-c C-e l l), gives me:

--8<---------------cut here---------------start------------->8---
\begin{document}

\maketitle
\tableofcontents

\section*{Section A, level 1}
\label{sec:orgheadline3}
\subsection*{Section AA, level 2}
\label{sec:orgheadline1}
Some AA text. 
\subsection*{Section AB, level 2}
\label{sec:orgheadline2}
Some AB text. 
\section*{Section B, level 1}
\label{sec:orgheadline6}
\subsection*{Section BA, level 2}
\label{sec:orgheadline4}
Some BA text. 
\subsection*{Section BB, level 2}
\label{sec:orgheadline5}
Some BB text. 
\end{document}
--8<---------------cut here---------------end--------------->8---

Please note the asterisks between section and it's next {.

In short, Org exports this:
\section*{

instead of this:
\section{

Of course, it breaks the syntax (as I understood it, I'm new to latex)
and messes up the latex to pdf transformation, at least with the 2
classes I tried (standard article and tufte-handout).

I'm running
+ GNU Emacs 24.5.1 compiled on 2015-11-09
+ Org-mode version 8.3.1 (8.3.1-95-g1dbb25-elpaplus @
~/.emacs.d/elpa/org-plus-contrib-20150831/)

I have nothing in my .emacs that sounds related to latex or latex export
except the tufte-latex classes declarations. 

The packages I have enabled are:
+ org-bullets-20140918.1137
+ helm-mu-20151019.944
+ helm-core-20150831.933
+ helm-20151117.2303
+ org-caldav-20150131.152
+ google-maps-20130412.230
+ calfw-20150831.1847
+ calfw-gcal-20120111.200
+ async-20150818.1154
+ table-20140721.2215
+ pdf-tools-20150716.643
+ let-alist-1.0.4
+ mu4e

Does anyone suffered something similar? Is there more information I can
provide to troubleshoot the root of this export issue? 

In every case, thank you very much. :)

Best...


-- 
eduardo mercovich 

 Donde se cruzan tus talentos 
 con las necesidades del mundo, 
 ahí está tu vocación.

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

* Re: Org is exporting to tex an asterisk between "section" and "{"
  2016-03-04 19:15 Org is exporting to tex an asterisk between "section" and "{" Eduardo Mercovich
@ 2016-03-04 19:45 ` Eric S Fraga
  2016-03-04 21:26   ` Eduardo Mercovich
  0 siblings, 1 reply; 10+ messages in thread
From: Eric S Fraga @ 2016-03-04 19:45 UTC (permalink / raw)
  To: Eduardo Mercovich; +Cc: emacs-orgmode

On Friday,  4 Mar 2016 at 16:15, Eduardo Mercovich wrote:
> Hello evoryone.
>
> Troubleshooting a lack of ToC content in a exported PDF from org, I
> found this issue.

Make sure you have

#+options: num:t

set.  Otherwise, sections are unnumbered.  I'm not sure what the default
is.  Maybe you have "num:nil"?
-- 
: Eric S Fraga (0xFFFCF67D), Emacs 25.0.91.1, Org release_8.3.4-626-gb62d55

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

* Re: Org is exporting to tex an asterisk between "section" and "{"
  2016-03-04 19:45 ` Eric S Fraga
@ 2016-03-04 21:26   ` Eduardo Mercovich
  2016-03-05 10:10     ` Eric S Fraga
  0 siblings, 1 reply; 10+ messages in thread
From: Eduardo Mercovich @ 2016-03-04 21:26 UTC (permalink / raw)
  To: Eric S Fraga; +Cc: emacs-orgmode

Hi Eric.

>> Troubleshooting a lack of ToC content in a exported PDF from org, I
>> found this issue. [...]

> Make sure you have
> #+options: num:t
> set.  Otherwise, sections are unnumbered.  I'm not sure what the default
> is.  Maybe you have "num:nil"?

I had nothing in the document, and your suggestion did the trick.
Thank you! :)

However, I can't find this in the documentation... shouldn't something
like this be the default? If not, the ToC and the links are not rendered
or non-functional.

Best.


-- 
eduardo mercovich 

 Donde se cruzan tus talentos 
 con las necesidades del mundo, 
 ahí está tu vocación.

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

* Re: Org is exporting to tex an asterisk between "section" and "{"
  2016-03-04 21:26   ` Eduardo Mercovich
@ 2016-03-05 10:10     ` Eric S Fraga
  2016-03-08 12:30       ` Eduardo Mercovich
  0 siblings, 1 reply; 10+ messages in thread
From: Eric S Fraga @ 2016-03-05 10:10 UTC (permalink / raw)
  To: Eduardo Mercovich; +Cc: emacs-orgmode

On Friday,  4 Mar 2016 at 18:26, Eduardo Mercovich wrote:
> Hi Eric.
>
>>> Troubleshooting a lack of ToC content in a exported PDF from org, I
>>> found this issue. [...]
>
>> Make sure you have
>> #+options: num:t
>> set.  Otherwise, sections are unnumbered.  I'm not sure what the default
>> is.  Maybe you have "num:nil"?
>
> I had nothing in the document, and your suggestion did the trick.
> Thank you! :)
>
> However, I can't find this in the documentation... shouldn't something
> like this be the default? If not, the ToC and the links are not rendered
> or non-functional.

It is documented, in [[info:org#Export%20settings][info:org#Export settings]],

,----
| ‘num:’
|      Toggle section-numbers (‘org-export-with-section-numbers’).  It can
|      also be set to a number ‘n’, so only headlines at that level or
|      above will be numbered.  Finally, irrespective of the level of a
|      specific headline, the numbering of it can be disabled by setting
|      the ‘UNNUMBERED’ property to non-‘nil’.  This also affects
|      subheadings.
`----

Easy to miss as it is not LaTeX specific, of course.  It's a general
setting that affects potentially any export engine but is obviously only
relevant to some.

-- 
: Eric S Fraga (0xFFFCF67D), Emacs 25.0.91.1, Org release_8.3.4-626-gb62d55

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

* Re: Org is exporting to tex an asterisk between "section" and "{"
  2016-03-05 10:10     ` Eric S Fraga
@ 2016-03-08 12:30       ` Eduardo Mercovich
  2016-03-10  8:56         ` Eric S Fraga
  2016-03-10  9:57         ` Nicolas Goaziou
  0 siblings, 2 replies; 10+ messages in thread
From: Eduardo Mercovich @ 2016-03-08 12:30 UTC (permalink / raw)
  To: Eric S Fraga; +Cc: emacs-orgmode

Dear Eric.

>>>> Troubleshooting a lack of ToC content in a exported PDF from org, I
>>>> found this issue. [...]

>>> Make sure you have
>>> #+options: num:t
>>> set.  Otherwise, sections are unnumbered.  I'm not sure what the default
>>> is.  Maybe you have "num:nil"?

>> I had nothing in the document, and your suggestion did the trick. [...]

>> However, I can't find this in the documentation... shouldn't something
>> like this be the default? If not, the ToC and the links are not rendered
>> or non-functional.

> It is documented, in [[info:org#Export%20settings][info:org#Export
> settings]], [...]
> Easy to miss as it is not LaTeX specific, of course.  It's a general
> setting that affects potentially any export engine but is obviously only
> relevant to some.

Sorry, I was totally unclear...

Being a total newbie I can't say that the resulting syntax is incorrect
(is it?), but at least in the case of latex, *not expressing this
specific option creates a non-functional latex file*. 

Shouldn't the exporter take care of this? Or at least, never export the
asterisk between the "section" and the brace (just in case, "{" since
I'm not an English native speaker).

Sorry if the case is irrelevant, I tried reading before posting but
found nothing to reassure me.

Thanks... :)


-- 
eduardo mercovich 

 Donde se cruzan tus talentos 
 con las necesidades del mundo, 
 ahí está tu vocación.

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

* Re: Org is exporting to tex an asterisk between "section" and "{"
  2016-03-08 12:30       ` Eduardo Mercovich
@ 2016-03-10  8:56         ` Eric S Fraga
  2016-03-15 16:07           ` Eduardo Mercovich
  2016-03-10  9:57         ` Nicolas Goaziou
  1 sibling, 1 reply; 10+ messages in thread
From: Eric S Fraga @ 2016-03-10  8:56 UTC (permalink / raw)
  To: Eduardo Mercovich; +Cc: emacs-orgmode

On Tuesday,  8 Mar 2016 at 09:30, Eduardo Mercovich wrote:

[...]

> Being a total newbie I can't say that the resulting syntax is incorrect
> (is it?), but at least in the case of latex, *not expressing this
> specific option creates a non-functional latex file*. 
>
> Shouldn't the exporter take care of this? Or at least, never export the
> asterisk between the "section" and the brace (just in case, "{" since
> I'm not an English native speaker).

The * between section and the brace indicates an unnumbered section
heading and is perfectly valid LaTeX syntax for the article class.  I am
not sure why you think the syntax is incorrect.

num:t tells org to export numbered headlines so the * won't be there in
that case.

-- 
: Eric S Fraga (0xFFFCF67D), Emacs 25.0.90.1, Org release_8.3.3-535-g7213aa

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

* Re: Org is exporting to tex an asterisk between "section" and "{"
  2016-03-08 12:30       ` Eduardo Mercovich
  2016-03-10  8:56         ` Eric S Fraga
@ 2016-03-10  9:57         ` Nicolas Goaziou
  2016-03-15 16:02           ` Eduardo Mercovich
  1 sibling, 1 reply; 10+ messages in thread
From: Nicolas Goaziou @ 2016-03-10  9:57 UTC (permalink / raw)
  To: Eduardo Mercovich; +Cc: emacs-orgmode

Hello,

Eduardo Mercovich <eduardo@mercovich.net> writes:

> Being a total newbie I can't say that the resulting syntax is incorrect
> (is it?), but at least in the case of latex, *not expressing this
> specific option creates a non-functional latex file*. 
>
> Shouldn't the exporter take care of this? Or at least, never export the
> asterisk between the "section" and the brace (just in case, "{" since
> I'm not an English native speaker).

By default, no asterisk is inserted (see
`org-export-with-section-numbers'). Something in your config is doing
it.

Regards,

-- 
Nicolas Goaziou

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

* Re: Org is exporting to tex an asterisk between "section" and "{"
  2016-03-10  9:57         ` Nicolas Goaziou
@ 2016-03-15 16:02           ` Eduardo Mercovich
  0 siblings, 0 replies; 10+ messages in thread
From: Eduardo Mercovich @ 2016-03-15 16:02 UTC (permalink / raw)
  To: Nicolas Goaziou; +Cc: emacs-orgmode

Dear Nicolas.

>> Being a total newbie I can't say that the resulting syntax is incorrect
>> (is it?), but at least in the case of latex, *not expressing this
>> specific option creates a non-functional latex file*. 

>> Shouldn't the exporter take care of this? Or at least, never export the
>> asterisk between the "section" and the brace (just in case, "{" since
>> I'm not an English native speaker).

> By default, no asterisk is inserted (see
> `org-export-with-section-numbers'). Something in your config is doing
> it.

I still didn't found it, but will keep searching.
I'm sure it's only my newbieness... :)

Thanks a lot.

Best...


-- 
eduardo mercovich 

 Donde se cruzan tus talentos 
 con las necesidades del mundo, 
 ahí está tu vocación.

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

* Re: Org is exporting to tex an asterisk between "section" and "{"
  2016-03-10  8:56         ` Eric S Fraga
@ 2016-03-15 16:07           ` Eduardo Mercovich
  2016-03-15 17:11             ` Eric S Fraga
  0 siblings, 1 reply; 10+ messages in thread
From: Eduardo Mercovich @ 2016-03-15 16:07 UTC (permalink / raw)
  To: Eric S Fraga; +Cc: emacs-orgmode

Dear Eric.

> [...]
>> Being a total newbie I can't say that the resulting syntax is incorrect
>> (is it?), but at least in the case of latex, *not expressing this
>> specific option creates a non-functional latex file*. [...]

> The * between section and the brace indicates an unnumbered section
> heading and is perfectly valid LaTeX syntax for the article class.  I am
> not sure why you think the syntax is incorrect.

Sorry, I found the references after the mail.

It is exactly as you said, valid. However, and I may be getting
something else incorrectly, pdflatex has problems with those as it works
out of the box (C-c C-e l o in org), since internal links are broken and
the ToC is not generated. 

It seems a special export case and it's documented, just not obvious for
the begginer. 

> num:t tells org to export numbered headlines so the * won't be there in
> that case.

With that option, it works wonderfully. :)))

Thanks a lot...


-- 
eduardo mercovich 

 Donde se cruzan tus talentos 
 con las necesidades del mundo, 
 ahí está tu vocación.

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

* Re: Org is exporting to tex an asterisk between "section" and "{"
  2016-03-15 16:07           ` Eduardo Mercovich
@ 2016-03-15 17:11             ` Eric S Fraga
  0 siblings, 0 replies; 10+ messages in thread
From: Eric S Fraga @ 2016-03-15 17:11 UTC (permalink / raw)
  To: Eduardo Mercovich; +Cc: emacs-orgmode

On Tuesday, 15 Mar 2016 at 13:07, Eduardo Mercovich wrote:

[...]

> It is exactly as you said, valid. However, and I may be getting
> something else incorrectly, pdflatex has problems with those as it works
> out of the box (C-c C-e l o in org), since internal links are broken and
> the ToC is not generated. 

A table of contents cannot be generated if the sections are not
numbered.  This is a LaTeX "feature".  Maybe org should check for
consistency between num: and toc: but every export target is potentially
different.

-- 
: Eric S Fraga (0xFFFCF67D), Emacs 25.0.91.1, Org release_8.3.4-626-gb62d55

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

end of thread, other threads:[~2016-03-15 17:11 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-03-04 19:15 Org is exporting to tex an asterisk between "section" and "{" Eduardo Mercovich
2016-03-04 19:45 ` Eric S Fraga
2016-03-04 21:26   ` Eduardo Mercovich
2016-03-05 10:10     ` Eric S Fraga
2016-03-08 12:30       ` Eduardo Mercovich
2016-03-10  8:56         ` Eric S Fraga
2016-03-15 16:07           ` Eduardo Mercovich
2016-03-15 17:11             ` Eric S Fraga
2016-03-10  9:57         ` Nicolas Goaziou
2016-03-15 16:02           ` Eduardo Mercovich

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).