Function: org-edit-comment-block
org-edit-comment-block is an interactive and byte-compiled function
defined in org-src.el.gz.
Signature
(org-edit-comment-block)
Documentation
Edit comment block at point.
A new buffer is created and the block is copied into it, and the buffer is switched into Org mode.
When done, exit with C-c ' (org-edit-src-exit). The edited text will
then replace the area in the Org mode buffer.
Throw an error when not at a comment block.
Key Bindings
Source Code
;; Defined in /usr/src/emacs/lisp/org/org-src.el.gz
(defun org-edit-comment-block ()
"Edit comment block at point.
\\<org-src-mode-map>
A new buffer is created and the block is copied into it, and the
buffer is switched into Org mode.
When done, exit with `\\[org-edit-src-exit]'. The edited text will
then replace the area in the Org mode buffer.
Throw an error when not at a comment block."
(interactive)
(let ((element (org-element-at-point)))
(unless (and (org-element-type-p element 'comment-block)
(org-src--on-datum-p element))
(user-error "Not in a comment block"))
(org-src--edit-element
element
(org-src--construct-edit-buffer-name (buffer-name) "org")
'org-mode
(lambda () (org-escape-code-in-region (point-min) (point-max)))
(org-unescape-code-in-string (org-element-property :value element)))
t))