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 13:14:56 +0200 Message-ID: References: <87k3ns89lk.fsf@gmail.com> <87bo949mgg.fsf@gmail.com> <717E4F0F-A573-4529-8BAD-0911E7BDDAC9@gmail.com> <86mwskxsmk.fsf@somewhere.org> 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]:53703) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UW35m-00062e-01 for emacs-orgmode@gnu.org; Sat, 27 Apr 2013 07:14:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UW35k-0003uQ-UV for emacs-orgmode@gnu.org; Sat, 27 Apr 2013 07:14:57 -0400 Received: from mail-we0-x22f.google.com ([2a00:1450:400c:c03::22f]:34324) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UW35k-0003uC-OX for emacs-orgmode@gnu.org; Sat, 27 Apr 2013 07:14:56 -0400 Received: by mail-we0-f175.google.com with SMTP id i48so1140574wef.34 for ; Sat, 27 Apr 2013 04:14:56 -0700 (PDT) In-Reply-To: <86mwskxsmk.fsf@somewhere.org> 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: Sebastien Vauban Cc: emacs-orgmode@gnu.org On 27.4.2013, at 10:52, Sebastien Vauban = wrote: > Hi Carsten, >=20 > Carsten Dominik wrote: >> On 24.4.2013, at 13:50, Nicolas Goaziou wrote: >>> Thorsten Jolitz writes: >>>=20 >>>> Exporting a Worg file with this header (#+TOC: headlines 2)=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. >>=20 >> 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. >>=20 >> What do you think? Are there good reasons for not doing it >> as I propose? >=20 > Maybe what I'll say is stupid, but, in LaTeX, there's the minitoc = package for > having a big TOC at the beginning of the document (default) + TOC per = chapter, > which can be limited to less (or more) sublevels. >=20 > Maybe allowing to insert extra TOC here and there would allow one to = make > something like that available to other backends? Though, as of today, = I don't > think the TOC is limitable per org-level-1 headline... >=20 Hi Sebastien, I am not saying multiple tocs should not be allowed. I am all for that. However, I think that by inserting a #+TOC line, the user indicates desire for local control. Therefore, org-export-with-toc should be = ignored, and, by extension, also #+OPTIONS: toc (because this is really a local = way to set org-export-with-toc). - Carsten