Function: org-link--buffer-for-internals
org-link--buffer-for-internals is a byte-compiled function defined in
ol.el.gz.
Signature
(org-link--buffer-for-internals)
Documentation
Return buffer used for displaying the target of internal links.
Source Code
;; Defined in /usr/src/emacs/lisp/org/ol.el.gz
(defun org-link--buffer-for-internals ()
"Return buffer used for displaying the target of internal links."
(cond
((not org-link-use-indirect-buffer-for-internals) (current-buffer))
((string-suffix-p "(Clone)" (buffer-name))
(message "Buffer is already a clone, not making another one")
;; We also do not modify visibility in this case.
(current-buffer))
(t ;make a new indirect buffer for displaying the link
(let* ((indirect-buffer-name (concat (buffer-name) "(Clone)"))
(indirect-buffer
(or (get-buffer indirect-buffer-name)
(make-indirect-buffer (current-buffer)
indirect-buffer-name
'clone))))
(with-current-buffer indirect-buffer (org-cycle-overview))
indirect-buffer))))