emacs-orgmode@gnu.org archives
 help / color / mirror / code / Atom feed
From: Nick Dokos <ndokos@gmail.com>
To: emacs-orgmode@gnu.org
Subject: Re: heading numbering in LaTeX export?
Date: Sun, 08 Sep 2013 00:05:45 -0400	[thread overview]
Message-ID: <87txhwrm92.fsf@gmail.com> (raw)
In-Reply-To: CAE+_6Tz1gN5dWffoP0Ow3sztwpgULBxiYE=_MzKPTAMrU=dBBw@mail.gmail.com

Peter Salazar <cycleofsong@gmail.com> writes:

> Thanks for the responses!
>
> John: Oh yes, of course. Sorry about that. inimal org file and config files are here. I had to make the org file long enough to make several pages, so the header displays. Here you
> go: 
> https://github.com/petersalazar/org-troubleshooting
>
> Rasmus: #+OPTIONS: num:0 is what I started from. When I do that, the resulting PDF has no Table of Contents, and the header displays the section title as "Contents." 
>
> The same thing happens with #+LATEX: \setcounter{secnumdepth}{0}.
>
> Richard: Your idea about 
> #+LATEX_HEADER: \renewcommand{...}
>
> sounds very promising! I'd love to know what the exact command is! 

The quick-and-dirty solution is

--8<---------------cut here---------------start------------->8---
#+LATEX_HEADER: \renewcommand{\thesection}{}
#+LATEX_HEADER: \renewcommand{\thesubsection}{}
#+LATEX_HEADER: \renewcommand{\thesubsubsection}{}
--8<---------------cut here---------------end--------------->8---

That's enough for the default secnumdepth of 3, but if you make that
bigger, you'll have to make it even dirtier:

--8<---------------cut here---------------start------------->8---
#+LATEX_HEADER: \renewcommand{\theparagraph}{}
#+LATEX_HEADER: \renewcommand{\thesubparagraph}{}
--8<---------------cut here---------------end--------------->8---

There is probably a cleaner way, but that would require cleverness
and I don't have any right now.

BTW, this turns off section numbers in the TOC as well, not just in the
body of the document.
--
Nick

  reply	other threads:[~2013-09-08  4:06 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-09-06 19:43 heading numbering in LaTeX export? Peter Salazar
2013-09-06 20:30 ` John Hendy
2013-09-07 22:51   ` Peter Salazar
2013-09-08  4:05     ` Nick Dokos [this message]
2013-09-08  4:59       ` Peter Salazar
2013-09-08  5:54         ` Nick Dokos
2013-09-08  7:43           ` Peter Salazar
2013-09-08 11:47             ` Nick Dokos
2013-09-08 16:58               ` Peter Salazar
2013-09-08 14:26     ` John Hendy
2013-09-07 20:21 ` Richard Lawrence
2013-09-07 20:41   ` Rasmus

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.orgmode.org/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87txhwrm92.fsf@gmail.com \
    --to=ndokos@gmail.com \
    --cc=emacs-orgmode@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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).