From mboxrd@z Thu Jan 1 00:00:00 1970 From: Johannes Rainer Subject: Re: R source code, break long lines Date: Tue, 13 May 2014 21:26:21 +0200 Message-ID: Mime-Version: 1.0 Content-Type: multipart/alternative; boundary=001a1133d50cf7d17204f94d0985 Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:45740) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WkILI-0004zU-A4 for emacs-orgmode@gnu.org; Tue, 13 May 2014 15:26:25 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1WkILH-00037l-7p for emacs-orgmode@gnu.org; Tue, 13 May 2014 15:26:24 -0400 Received: from mail-lb0-x231.google.com ([2a00:1450:4010:c04::231]:48957) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1WkILG-00037g-RK for emacs-orgmode@gnu.org; Tue, 13 May 2014 15:26:23 -0400 Received: by mail-lb0-f177.google.com with SMTP id s7so638536lbd.22 for ; Tue, 13 May 2014 12:26:21 -0700 (PDT) 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: John Hendy Cc: emacs-orgmode --001a1133d50cf7d17204f94d0985 Content-Type: text/plain; charset=ISO-8859-1 On Tue, May 13, 2014 at 6:16 PM, John Hendy wrote: > On Tue, May 13, 2014 at 1:04 AM, Johannes Rainer > wrote: > > dear all, > > > > I'm extensively using org-mode in combination with R source code blocks. > The > > only thing I miss is the possibility to break long lines of R code in the > > exported pdf. > > Is there a way to tell org, or the latex exporter, to have automatic line > > breaks for long lines? > > > > I think these are treated as verbatim... so what's in your buffer is > what you'll get in PDF. You might consider editing the block with C-c > ' (Ctrl + C, then single quote). From there, when you hit a reasonable > point (<=80 characters), press return and Org will auto-indent things > pretty nicely, at least in my experience with R. > > right, that's the way I'm doing it now. just thought I missed some "automatic" way to do that. thanks! > If you get odd results, perhaps check this thread, as I was having > issues with Org exporting the code blocks exactly as I'd typed them: > - https://www.mail-archive.com/emacs-orgmode@gnu.org/msg81100.html > > Tl;dr is that you should check the variables > org-src-preserve-indentation, and possibly the variable > indent-tabs-mode. > > > so far, ess/org or however formatted the code nicely for me after pressing return in the ess mode buffer > Best regards, > John > > > thanks in advance! > > > > cheers, jo > --001a1133d50cf7d17204f94d0985 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable



--001a1133d50cf7d17204f94d0985--