From mboxrd@z Thu Jan 1 00:00:00 1970 From: Indraneel Majumdar Subject: Re: Header levels and section numbering > 3, in LaTeX export Date: Fri, 08 Oct 2010 15:54:42 +0530 Message-ID: <4CAEF16A.3050508@indraneel.info> References: <4CABEEA0.1070304@limist.com> <8493.1286343502@gamaville.dokosmarshall.org> <4CAD1D17.5060906@indraneel.info> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Return-path: Received: from [140.186.70.92] (port=51747 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1P4AbZ-0007bC-2R for emacs-orgmode@gnu.org; Fri, 08 Oct 2010 06:55:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1P4A7b-0006R3-N9 for emacs-orgmode@gnu.org; Fri, 08 Oct 2010 06:24:18 -0400 Received: from mailout05.yourhostingaccount.com ([65.254.253.42]:55238) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1P4A7b-0006Qb-LG for emacs-orgmode@gnu.org; Fri, 08 Oct 2010 06:24:15 -0400 Received: from mailscan21.yourhostingaccount.com ([10.1.15.21] helo=mailscan21.yourhostingaccount.com) by mailout05.yourhostingaccount.com with esmtp (Exim) id 1P4A7X-0005lB-Hg for emacs-orgmode@gnu.org; Fri, 08 Oct 2010 06:24:11 -0400 In-Reply-To: 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: Scot Becker Cc: emacs-orgmode@gnu.org >> I couldn't get easylist to understand the >> \star symbol that orgmode uses. Do you know how to do that? > No. You might have seen the footnote in the easylist documentation > (on p. 2) which says: > > "You might not be happy with the symbols and maybe you'd like to use > another one, or simply have your favorite symbol > as default to avoid remembering such a cumbersome name as 'pilcrow'. > Here's a simple hack that does the job: select the > entire code of the package, and replace all occurrences of Ÿ (<<-- the > pilcrow) with your symbol. Make sure you won't use it in the list for > other purposes, though." > > I've not tried this, however. It would be nice if there were a dead > easy way to get easylist and org-mode to work well together, since the > two are very natural partners. Let me know if you can make this work. > I couldn't get either \star nor \ast to work so I'm just using \sharp now, and am simply replacing # (at beginning of the line) with a hook. I'm not sure which is the best hook to use though. I don't want to alter my orgmode buffer and also want the hook to run on orgmode syntax. So far, I've failed at this. org-export-first-hook runs in my orgmode buffer and alters the contents. org-export-latex-after-blockquotes-hook runs after latex export has already happened (ie \section etc have already been converted) Maybe there's a hook in the middle somewhere, but I couldn't find any documentation on it. >> And also to skip >> the first 3 stars in a level4 heading (if I want to retain latex's default >> top 3 levels)? > I've never actually gone all the way to making a document > easy-to-publish with Easylist. I've just manually converted > org-mode's stars to a character Easylist can understand, then manually > wrapped the whole thing in a LaTeX preamble. The ideal would be to > automate the process, perhaps by using org-babel and putting your > easylist sections in special code blocks. But I've not taken the time > to figure all that out. I do not even know what babel is, although I've heard it in a ton of different contexts. Considering what the word "babel" means, I'm not even sure if that is strange or not! > Failing that, I bet you could do a halfway hack with minimal amount of > manual work. For example (if I understand you correctly), you could > make an org document like this: > > * Regular org heading > ** Subheading > ** Here's a third-level heading > STARTLIST > **** My first thesis, which is longer and wordier than it probably should be. > ***** Of course it's nothing compared to the length of its supporting arguments > ***** Both of them > **** Here is my second thesis, as convincing as the first > ENDLIST > > Org-mode will let you do all of that, just fine. Then either > manually, or with a temporary latex export hook, do something like > this: > > replace STARTLIST with \begin{easylist} and ENDLIST with \end{easylist} > replace '**** ' with '& ' and '***** ' with'&& ' and ****** ' with'&&& ', etc. > > > If you do it in an export hook, I think you'd want to do it in one > that runs before everything else. That way org-mode will leave > everthing in your easylist environment alone. What that will do to > quotation marks and /emphasis/ I don't know. > This is exactly what I want to do, but which export hook to use? Something that will not modify my original buffer and also understand regexp that I can base on what was originally in my buffer. So instead of searching for \paragraph, I can search for "**** ", but I want to keep "**** " in my original org buffer. Indraneel > This should leave you with an easylist which starts at level '1', in a > document which uses org's header levels 1-3 in the normal latex way. > Is that what you want? > > Make sure in the preamble, you have \usepackage[ampersand]{easylist} > > Let me know if you need help figuring any of this out in detail. > That's just a rough sketch. > > Cheers, > > Scot > > _______________________________________________ > Emacs-orgmode mailing list > Please use `Reply All' to send replies to the list. > Emacs-orgmode@gnu.org > http://lists.gnu.org/mailman/listinfo/emacs-orgmode >