Function: hsys-org-search-radio-target-link-p

hsys-org-search-radio-target-link-p is a byte-compiled function defined in hsys-org.el.

Signature

(hsys-org-search-radio-target-link-p TARGET)

Documentation

Search from point for a radio target link matching TARGET.

White spaces are insignificant. Return t if a target link is found, else nil.

Source Code

;; Defined in ~/.emacs.d/elpa/hyperbole-20260414.325/hsys-org.el
;; Adapted from Org code
(defun hsys-org-search-radio-target-link-p (target)
  "Search from point for a radio target link matching TARGET.
White spaces are insignificant.  Return t if a target link is found, else nil."
  (when (string-match "<<<.+>>>" target)
    (setq target (substring target 3 -3)))
  (let ((re (format "%s" (mapconcat #'regexp-quote
                                    (split-string target)
                                    "[ \t]+\\(?:\n[ \t]*\\)?")))
	(origin (point)))
    (catch :radio-match
      (while (re-search-forward re nil t)
	(backward-char)
	(let ((object (org-element-context)))
	  (when (eq (org-element-type object) 'link)
	    (when (featurep 'org-fold) ;; newer Org versions
              (org-fold-show-context 'link-search))
	    (throw :radio-match t))))
      (goto-char origin)
      nil)))