[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[O] Super indent when editing R blocks and using a # comment
From: |
John Hendy |
Subject: |
[O] Super indent when editing R blocks and using a # comment |
Date: |
Thu, 28 Jan 2016 15:58:21 -0600 |
Find attached a screenshot of the behavior I'm experiencing with this
minimal config and =emacs -Q=.
#+begin_src min-config
;; set load paths
;; set load dirs and global config options
(add-to-list 'load-path "~/.elisp/org.git/lisp/")
(add-to-list 'load-path "~/.elisp/org.git/contrib/lisp")
(add-to-list 'load-path "~/.elisp/ess/lisp/")
(require 'ess-site)
;; setup babel languages
(org-babel-do-load-languages
'org-babel-load-languages
'((R . t)))
#+end_src
As shown in the shot:
- create a .org file, insert a #+begin/end_src R block
- edit with =C-c '=
- start a line with a comment char (#)
- press RET
- it gets indented halfway across the page
Inside a function, it seems to use a default of four spaces (the
position of =return(i^2)=), so I'm not sure why a comment triggers
such a massive indent. I end up having to delete the preceding spaces
or be super careful about having a newline already inserted so that I
can arrow down instead of pressing RET at the end of a comment line.
Thanks for any insights!
John
2016-01-28_155416.png
Description: PNG image
- [O] Super indent when editing R blocks and using a # comment,
John Hendy <=