From mboxrd@z Thu Jan 1 00:00:00 1970 From: Carsten Dominik Subject: Re: [BUG] New exporter exports TOC twice Date: Sat, 27 Apr 2013 10:44:31 +0200 Message-ID: <717E4F0F-A573-4529-8BAD-0911E7BDDAC9@gmail.com> References: <87k3ns89lk.fsf@gmail.com> <87bo949mgg.fsf@gmail.com> Mime-Version: 1.0 (Mac OS X Mail 6.3 \(1503\)) Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable Return-path: Received: from eggs.gnu.org ([208.118.235.92]:52611) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UW0kC-0007Hl-OW for emacs-orgmode@gnu.org; Sat, 27 Apr 2013 04:44:34 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UW0kB-0006OA-LM for emacs-orgmode@gnu.org; Sat, 27 Apr 2013 04:44:32 -0400 Received: from mail-we0-x236.google.com ([2a00:1450:400c:c03::236]:52529) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UW0kB-0006O4-Df for emacs-orgmode@gnu.org; Sat, 27 Apr 2013 04:44:31 -0400 Received: by mail-we0-f182.google.com with SMTP id s43so4197490wey.41 for ; Sat, 27 Apr 2013 01:44:30 -0700 (PDT) In-Reply-To: <87bo949mgg.fsf@gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Nicolas Goaziou Cc: emacs-orgmode@gnu.org, Thorsten Jolitz On 24.4.2013, at 13:50, Nicolas Goaziou wrote: > Hello, >=20 > Thorsten Jolitz writes: >=20 >> Exporting a Worg file with this header (#+TOC: headlines 2)=20 >>=20 >> = ,-------------------------------------------------------------------------= ---------------- >> | #+OPTIONS: H:3 num:nil \n:nil @:t ::t |:t ^:{} -:t f:t *:t TeX:t = LaTeX:t >> | skip:nil d:(HIDE) tags:not-in-toc >> | #+TOC: headlines 2 >> | #+STARTUP: align fold nodlcheck hidestars oddeven lognotestate = hideblocks >> | #+SEQ_TODO: TODO(t) INPROGRESS(i) WAITING(w@) | DONE(d) = CANCELED(c@) >> | #+TAGS: Write(w) Update(u) Fix(f) Check(c) noexport(n) >> | #+TITLE: Header arguments and result types in Org Babel >> | #+AUTHOR: Thorsten Jolitz, Eric Schulte >> | #+EMAIL: tj[at]data-driven[dot]de >> | #+LANGUAGE: en >> | #+LINK_UP: index.php >> | #+LINK_HOME: http://orgmode.org/worg/ >> | #+EXPORT_EXCLUDE_TAGS: noexport >> |=20 >> | For a complete header argument reference see the Org-mode manual's = page >> | which lists all >> | = [[http://orgmode.org/manual/Specific-header-arguments.html][Specific-heade= r-arguments]]. >> | This page holds ancillary notes and tricks which have not made it = into >> | the manual. >> |=20 >> | * Generally use =3Dverbatim=3D when using =3Ddrawer=3D, =3Draw=3D = or =3Dorg=3D >> | We often want to add =3Dverbatim=3D (which inhibits interpretation = as a >> | value, which can often result in a list or table result), when >> | inserting results directly into the buffer using =3Ddrawer=3D, = =3Draw=3D or >> | =3Dorg=3D which don't do tabular interpretation. [...] >> = `-------------------------------------------------------------------------= ---------------- >>=20 >> exports the TOC twice in HTML export and ASCII export.=20 >=20 > If you don't specify a toc item in the OPTIONS line, Org will use the > value of `org-export-with-toc', which is non-nil by default. >=20 > So, your example is equivalent to: >=20 > #+OPTIONS: toc:t > #+TOC: headline 2 >=20 > Hence you get two tables of contents. Hmm, I understand the reasoning here - but my feeling says that the presence of one or more #+TOC lines in a file should probably overrule both #+OPTIONS: toc: and the content of org-export-with-toc. So in that case, your would then only get one TOC, at the location of that line. What do you think? Are there good reasons for not doing it as I propose? - Carsten=