Function: klink:absolute
klink:absolute is a byte-compiled function defined in klink.el.
Signature
(klink:absolute LABEL-AND-POS)
Documentation
Return an absolute klink string from LABEL-AND-POS list.
With point in a klink's source buffer and LABEL-AND-POS a list
of (klink-label, klink-start, klink-end) including delimiters,
return an absolute klink string. Klink returned is of the form:
"<absolute-file-name, cell-ref>". See documentation for
kcell:ref-to-id for valid cell-ref formats.
Source Code
;; Defined in ~/.emacs.d/elpa/hyperbole-20260414.325/kotl/klink.el
;;; ************************************************************************
;;; Public functions
;;; ************************************************************************
(defun klink:absolute (label-and-pos)
"Return an absolute klink string from LABEL-AND-POS list.
With point in a klink's source buffer and LABEL-AND-POS a list
of (klink-label, klink-start, klink-end) including delimiters,
return an absolute klink string. Klink returned is of the form:
\"<absolute-file-name, cell-ref>\". See documentation for
`kcell:ref-to-id' for valid cell-ref formats."
(when (and (derived-mode-p 'kotl-mode) label-and-pos (listp label-and-pos))
(let* ((file-and-cell-ref (klink:parse (car label-and-pos)))
(file (or (car file-and-cell-ref) (hypb:buffer-file-name)))
(cell-ref (nth 1 file-and-cell-ref)))
(klink:set-yank-handler
(format "<%s#%s>" (expand-file-name file) cell-ref)))))