Function: hui:ibut-delete-op
hui:ibut-delete-op is a byte-compiled function defined in hui.el.
Signature
(hui:ibut-delete-op INTERACTIVE BUT-KEY KEY-SRC)
Documentation
INTERACTIVEly or not, delete implicit button given by BUT-KEY in KEY-SRC.
The BUT-KEY is the text key, not the name key.
KEY-SRC may be a buffer or a pathname; when nil the current buffer is used. Return t if button is deleted, signal error otherwise. If called with INTERACTIVE non-nil, derive BUT-KEY from the button that point is within.
Source Code
;; Defined in ~/.emacs.d/elpa/hyperbole-20260414.325/hui.el
(defun hui:ibut-delete-op (interactive but-key key-src)
"INTERACTIVEly or not, delete implicit button given by BUT-KEY in KEY-SRC.
The BUT-KEY is the text key, not the name key.
KEY-SRC may be a buffer or a pathname; when nil the current buffer is used.
Return t if button is deleted, signal error otherwise. If called
with INTERACTIVE non-nil, derive BUT-KEY from the button that point is
within."
(let ((buf (current-buffer)) (ibut))
(if (if interactive
(ibut:delete)
(cond ((or (null key-src) (and (bufferp key-src) (setq buf key-src)))
(setq ibut (ibut:get but-key nil key-src)))
((and (stringp key-src)
(setq buf (find-file-noselect key-src)))
(setq ibut (ibut:get but-key buf)))
(t (hypb:error "(ibut-delete): Invalid key-src: '%s'" key-src)))
(if ibut
(ibut:delete ibut)
(hypb:error "(ibut-delete): No valid %s button in %s"
(ibut:key-to-label but-key) buf)))
(progn (set-buffer buf)
(when (hmail:reader-p) (hmail:msg-narrow))
(message "Button '%s' deleted." (ibut:key-to-label but-key)))
(hypb:error "(ibut-delete): You may not delete buttons from this buffer"))))