From mboxrd@z Thu Jan 1 00:00:00 1970 From: Dan Davison Subject: Re: Help: Getting ESS key binding to work with a R code block in org-mode Date: Sun, 21 Nov 2010 20:17:45 +0000 Message-ID: <87y68mctxy.fsf@gmail.com> References: Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from [140.186.70.92] (port=41113 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PKGMx-00065D-Sx for emacs-orgmode@gnu.org; Sun, 21 Nov 2010 15:18:41 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PKGMu-0003Yy-OW for emacs-orgmode@gnu.org; Sun, 21 Nov 2010 15:18:39 -0500 Received: from markov.stats.ox.ac.uk ([163.1.210.1]:45393) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PKGMu-0003YW-DQ for emacs-orgmode@gnu.org; Sun, 21 Nov 2010 15:18:36 -0500 In-Reply-To: (Sunny Srivastava's message of "Sun, 21 Nov 2010 14:11:47 -0500") 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: Sunny Srivastava Cc: emacs-orgmode mailing list Sunny Srivastava writes: > Hello Org-moders, > I have been a very happy ESS user so far. Recently, I was introduced to > org-mode and I am still a beginner. > > I am trying to write a research paper using the literate programming style > of org-babel-R, instead of Sweave, and the journey has been OK so far. I > have a very lame question related to this, so please bear with me. > > I am used to the ESS key-bindings, however they don't work properly in the > code block (begin_src R ... end_src). I googled and found that it is > recommended to use C-c ` to edit the source code in an Org-tmp buffer. > However, there are a few issues related to this: Hi Sunny, A couple of possibilities to solve your current problems: Firstly, the key combination is C-c ' not C-c ` i.e., that character is a straight single quote. Secondly, have you activated R as an Org-babel language? See section 14.7 of the manual. You can do it with customize, or you can do it by adding some emacs-lisp to your .emacs file. E.g. the following activates emacs-lisp and R: (org-babel-do-load-languages 'org-babel-load-languages '((emacs-lisp . t) (R . t))) Don't hesitate to get back to the list if you have further questions. Dan > > 1. Let's say I have a code block which contains some code in it. When I do > C-c ` a temporary buffer opens up but it doesn't include the R code that was > in the code block. > 2. The temporary buffer for editing R code doesn't associate itself with > ESS, ie the key-bindings don't work. (I am addicted to the "smart _" key > binding of ESS as well I am facing problems indenting the code using C-M-\) > > Any help or pointers is much appreciated. > > Thanks to Eric and other developers for implementing such a great idea. > > > Version: 7.3 (release_7.3-89-g97f4c > _______________________________________________ > 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