From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Thomas S. Dye" Subject: Re: How to do proper folding and semantic markup Date: Wed, 30 Mar 2016 11:52:25 -1000 Message-ID: References: <87vb438zm8.fsf@mercovich.net> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:49210) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1alO3q-0008ID-7T for emacs-orgmode@gnu.org; Wed, 30 Mar 2016 17:53:59 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1alO3m-0000NU-5i for emacs-orgmode@gnu.org; Wed, 30 Mar 2016 17:53:58 -0400 Received: from gproxy9-pub.mail.unifiedlayer.com ([69.89.20.122]:35964) by eggs.gnu.org with smtp (Exim 4.71) (envelope-from ) id 1alO3l-0000NL-VD for emacs-orgmode@gnu.org; Wed, 30 Mar 2016 17:53:54 -0400 In-reply-to: <87vb438zm8.fsf@mercovich.net> 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: Eduardo Mercovich Cc: Org-mode Aloha Eduardo, You might find Aaron Ecay's ox-extra.el in contrib useful. It defines an :ignore: tag that instructs the exporter to ignore the headline it tags, but still export the text, etc. under the headline. So, ,---------------------------- | * Abstract :ignore: | | #+begin_abstract | The abstract ... | #+end_abstract | | * Chapter 1 `---------------------------- will give you an abstract before Chapter 1 and you'll still be able to fold it out of the way when you don't want to see it. hth, Tom Eduardo Mercovich writes: > Dear all. > > I'm using org-mode as a writer and it is simply fantastic. One of the > things I enjoy more is the folding. A huge report like the one I'm > working on seems sooo easy... ;) > > However, I don't know how to integrate that with some semantic markup > and the latex exporter at the same time (BTW, org+latex=awesomness!). > > I'll use the abstract as example, but the same idea is valid for other > semantic markup like front, main and backmatter. > > As a MWE let's see this org file. > > --8<---------------cut here---------------start------------->8--- > [some latex preamble] > > * Abstract > > The abstract body text (even with some level 2 headers in the middle). > > * Process > > ** A level 2 header > > It's body text and the rest of the report... > --8<---------------cut here---------------end--------------->8--- > > When this is exported to latex (using a slightly modified memoir class), > the 1st header has "Abstract" as title, but doesn't express that it *is* > an abstract. So, for example, it can be styled, or it can be searched > inside specifically. > > The org manual(1), says: > > ... place the abstract and #+LATEX: commands for frontmatter before the > first exported headline, e.g., > #+BEGIN_abstract > [Abstract here] > #+END_abstract > > The question is: how do I use the 1st header (keeping it's folding and > referencing in org) while at the same time expressing that it is an > abstract? How (if) can be done not only before the ToC, LoF and LoT but > after them? > > I already tried this, without success: > > --8<---------------cut here---------------start------------->8--- > [some latex preamble] > > * Abstract > #+BEGIN_abstract > > The abstract body text (even with some level 2 headers in the middle). > > #+END_abstract > > * Process > > It's body text and the rest of the report... > --8<---------------cut here---------------end--------------->8--- > > > Is there is no mechanism yet (which I doubt) and if it makes sense, is > it possible to use properties for this? Something like: > > --8<---------------cut here---------------start------------->8--- > [some latex preamble] > > * Abstract > :PROPERTIES: > :latex-type: abstract > :END: > > The abstract body text (even with some level 2 headers in the middle). > > * Process > > It's body text and the rest of the report... > --8<---------------cut here---------------end--------------->8--- > > In this way each exporter backend can use that info as it pleases. Latex > to use it's specific markup, html to make a class, etc. > > Please forgive me if the answer is obvious, but I've searched and found > nothing. I did my homework and I'm sure it's there, but obviously I'm > not searching with the appropiate keywords. > > As always, thank you in advance for sharing your time and experience. :) > > Best... > > > > (1) http://orgmode.org/worg/org-tutorials/org-latex-export.html#orgheadline17 -- Thomas S. Dye http://www.tsdye.com