From mboxrd@z Thu Jan 1 00:00:00 1970 From: Mark Elston Subject: Re: Sectioning in LaTeX export Date: Wed, 08 Apr 2009 07:57:08 -0700 Message-ID: <49DCBB44.1030204@comcast.net> References: <49DC0349.4040906@comcast.net> <49DC08FB.5000808@comcast.net> <9135.1239160927@gamaville.dokosmarshall.org> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Return-path: Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1LrZDT-00036K-5H for emacs-orgmode@gnu.org; Wed, 08 Apr 2009 10:57:27 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1LrZDR-00035C-9N for emacs-orgmode@gnu.org; Wed, 08 Apr 2009 10:57:26 -0400 Received: from [199.232.76.173] (port=45528 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1LrZDR-000356-3f for emacs-orgmode@gnu.org; Wed, 08 Apr 2009 10:57:25 -0400 Received: from qmta11.emeryville.ca.mail.comcast.net ([76.96.27.211]:50949) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1LrZDQ-0001nl-G1 for emacs-orgmode@gnu.org; Wed, 08 Apr 2009 10:57:24 -0400 In-Reply-To: <9135.1239160927@gamaville.dokosmarshall.org> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: org-mode emacs-orgmode Nick Dokos wrote: > Mark, > > I tried (on Org-mode version 6.25b) the following simple test and it > seems to work OK (see attached tex.file) - note that (at least afaik) > there is a one-one correspondence between the heading level and the > LaTeX construct: that is controlled in a limited way by the variable > org-export-latex-classes (see below). > > * main file book.org: > > ,---- > | #+TITLE: My Tasks > | #+OPTIONS: H:5 num:t d:nil > | #+LaTeX_CLASS: book > | > | > | * Part 1 > | #+INCLUDE: "ch1.org" > | > | #+INCLUDE: "ch2.org" > `---- > It appears that the key is in this file. This file *must* have a headline of level 1 or nothing else works. Who knew? (Except Carsten, of course) :) > > * Chapter 1 file: > > ,---- > | ** First chapter > | *** Introduction > | *** Elaboration > | *** Proof > | **** Subsection 3.1 > | **** Subsection 3.2 > | *** Summary > `---- > > * Chapter 2 file: > > ,---- > | ** Chapter 2 > | *** Section 1 > | *** Section 2 > | **** Subsection 2.1 > | **** Subsection 2.2 > | *** Section 3 > | *** Section 4 > `---- > > But you'll have to compromise a bit: > > o you'll have to make the chapters at least level 1 - but you can > use M-S- or M-S- to demote/promote the whole tree, > as long as the top level is >= 1. > Your example doesn't show this as both have level 2 trees, but, yes, if the main file has a level 1 headline *before* including any further files then the structure is honored. This is a little awkward but not too bad. > o you can edit the book portion of org-export-latex-classes to change the > correspondence of level to LaTeX construct: > Yeah, I am using a custom org-export-latex-classes so I can use memoir and do some further customizations. > ... > o Note also that the H:5 setting controls not only the tocdepth > in LaTeX but it also affects how levels >= (H value) correspond > to LaTeX constructs - what would become a subsection given a high > enough value for H, actually becomes an \itemize for a lower value. > I observer this experimentally and I have no idea if there is some > other way of getting around it. > I am going to play around with this. I looked at the code for the latex exporting and had trouble following it (I am not a lisp expert by any means). Thanks for discovering this. I would not have tried this as I am keeping different kinds of information in different files and simply using a 'main' file to group them for 'pretty-printing'. It's not really a book. It is my notes of ongoing tasks for my team that I use for my 'Management by Walking Around' style... :) One chapter is for ongoing tasks, one chapter for bugs, one chapter for project schedule items, etc. They are short chapters but having it all collected simplifies my life when I go into meetings and need to report on the progress of any particular item. Mark