Function: ibtypes::hynote-file

ibtypes::hynote-file is a byte-compiled function defined in hynote.el.

Signature

(ibtypes::hynote-file)

Documentation

When on a HyNote file name stem, display the file and its optional section.

This type is active only in buffers where hywiki-active-in-current-buffer-p is true. This may require that hywiki-mode(var)/hywiki-mode(fun) has been enabled.

Source Code

;; Defined in ~/.emacs.d/elpa/hyperbole-20260414.325/hynote.el
(defib hynote-file ()
  "When on a HyNote file name stem, display the file and its optional section.
This type is active only in buffers where `hywiki-active-in-current-buffer-p'
is true.  This may require that `hywiki-mode' has been enabled."
  (when (hywiki-active-in-current-buffer-p)
    (cl-destructuring-bind (file-stem-name start end)
	(hynote-file-stem-start-end-at)
      (when file-stem-name
	(let ((file (hynote-get-file file-stem-name))
	      section)
	  (when (and file (file-readable-p file))
	    (setq section (when (string-match "#" file-stem-name)
			    (substring file-stem-name (match-beginning 0))))
	    (ibut:label-set file-stem-name start end)
	    (hact 'hynote-find-file file section)))))))