From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nick Dokos Subject: Re: BUG: example/src blocks and latex export Date: Fri, 19 Aug 2011 18:03:44 -0400 Message-ID: <12981.1313791424@alphaville.dokosmarshall.org> References: <6977.1313748571@alphaville.dokosmarshall.org> <874o1d6qi4.fsf@gnu.org> Reply-To: nicholas.dokos@hp.com Return-path: Received: from eggs.gnu.org ([140.186.70.92]:38701) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QuXAN-0003R7-7E for emacs-orgmode@gnu.org; Fri, 19 Aug 2011 18:03:51 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QuXAK-0005ln-HS for emacs-orgmode@gnu.org; Fri, 19 Aug 2011 18:03:51 -0400 Received: from g4t0016.houston.hp.com ([15.201.24.19]:32748) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QuXAK-0005la-CR for emacs-orgmode@gnu.org; Fri, 19 Aug 2011 18:03:48 -0400 In-Reply-To: Message from Bastien of "Fri, 19 Aug 2011 23:27:47 +0200." <874o1d6qi4.fsf@gnu.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: Bastien Cc: nicholas.dokos@hp.com, emacs-orgmode@gnu.org Bastien wrote: > Hi Nick, > > Nick Dokos writes: > > > * foo > > > > Verbiage to begin the paragraph > > #+begin_src shell > > get-config.py var section [section ...] > > #+end_src > > and verbiage to end the same paragraph. > > > > * bar > > > > Verbiage to begin the paragraph > > #+begin_example > > get-config.py var section [section ...] > > #+end_example > > and verbiage to end the same paragraph. > > I tested your patch with the example above and I get this: > > ,---- > | Verbiage to begin the paragraph > | > | \lstset{language=shell} > | \begin{lstlisting} > | get-config.py var section [section ...] > | \end{lstlisting} > | > | and verbiage to end the same paragraph. > | \section*{bar} > | \label{sec-2} > | > | > | Verbiage to begin the paragraph > | > | \begin{verbatim} > | get-config.py var section [section ...] > | \end{verbatim} > | and verbiage to end the same paragraph. > `---- > > It looks better than the current export (less white lines) but still > has a problem with the first "and verbiage..." being indented. > > Is this intentional? Or do you want the same behavior for #+begin_src > and #+begin_example? > Not intentional. But I have org-export-latex-listings set to nil, so in my case, the src block gets turned into a verbatim environment, not into a listings environment, and there is no empty line there. Let me play around a bit with org-export-latex-listings and see. I guess the change in org-latex-verbatim-wrap takes care of my case, but there is another (gratuitous?) newline inserted after listings. > In overall, I think number of white lines should be the same in the > Org source file and in the LaTeX exported file, so a patch here is > welcome. But maybe I misunderstood something in Eric's reply. I tend to agree, but I can also understand Eric's wish for visual separation. However, as I pointed out in my earlier reply to him, I think that's a separate problem, not addressed (or affected) by this patch. Thanks for testing, Nick