all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Super indent when editing R blocks and using a # comment
@ 2016-01-28 21:58 John Hendy
  2016-01-28 22:21 ` Ista Zahn
  0 siblings, 1 reply; 3+ messages in thread
From: John Hendy @ 2016-01-28 21:58 UTC (permalink / raw)
  To: emacs-orgmode

[-- Attachment #1: Type: text/plain, Size: 1033 bytes --]

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

[-- Attachment #2: 2016-01-28_155416.png --]
[-- Type: image/png, Size: 70019 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2016-01-28 22:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-01-28 21:58 Super indent when editing R blocks and using a # comment John Hendy
2016-01-28 22:21 ` Ista Zahn
2016-01-28 22:52   ` John Hendy

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.