[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Orgmode] Re: [BABEL] Seemless editing of Babel Blocks

From: Jambunathan K
Subject: [Orgmode] Re: [BABEL] Seemless editing of Babel Blocks
Date: Mon, 16 Aug 2010 14:08:21 +0530
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/23.1.91 (windows-nt)

Apologize for duplicate post. Ccing the mailing list this time.

    Eric> Hi Jambunathan, I like the idea of displaying the
    Eric> begin/end_src lines as commented sections in the
    Eric> org-edit-special code buffer, and then potentially using them
    Eric> to change the values of the begin/end_src lines in the
    Eric> original org-mode buffer after exiting the src-edit buffer.
    Eric> It would be very cool to be able to edit header arguments
    Eric> while editing source code.  It may be hard to implement, but
    Eric> could be worth the effort.

Based on my experimentation, offering of #+begin_src and #+end_src
lines (or for that matter 'surrounding context' - leading and
trailing) is not problematic as such.

What really gets in the way (in the sense of being irksome to implement)
is the preserving and restoring of indentations while moving between the
org and org-src buffers.

I am giving up my efforts on this proposal.

1 Original Proposal 

What is this in org-buffer

  (defun hello () 
    (message "Hello World")

gets offered as 

;; #+begin_src emacs-lisp
(defun hello () 
  (message "Hello World")
;; #+end_src

in org-src buffer.

All that babel has to do is to run 'comment-region' and
'uncomment-region' on leading and trailing contexts before moving into
and out-of org-src buffers. 

(un)comment-region makes sure that this could be done in a target
language agnostic way. 

Furthermore, the way emacs fills out comment blocks (while editing
them) would retain the org-like structure of the surrounding context.

Jambunathan K.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]