Function: hui:menu-act
hui:menu-act is a byte-compiled function defined in hui-mini.el.
Signature
(hui:menu-act MENU &optional MENU-LIST DOC-FLAG HELP-STRING-FLAG)
Documentation
Prompt user with Hyperbole MENU (a symbol) and perform selected item.
Optional second argument MENU-LIST is a Hyperbole menu list structure from which to extract MENU. It defaults to hui:menus. See its definition for the menu list structure.
Two additional optional arguments may be given when documentation for a menu item should be shown rather than display of a menu. DOC-FLAG non-nil means show documentation for any item that is selected by the user. HELP-STRING-FLAG non-nil means show only the first line of the documentation, not the full text.
Source Code
;; Defined in ~/.emacs.d/elpa/hyperbole-20260414.325/hui-mini.el
(defun hui:menu-act (menu &optional menu-list doc-flag help-string-flag)
"Prompt user with Hyperbole MENU (a symbol) and perform selected item.
Optional second argument MENU-LIST is a Hyperbole menu list structure from
which to extract MENU. It defaults to `hui:menus'. See its definition for
the menu list structure.
Two additional optional arguments may be given when documentation for
a menu item should be shown rather than display of a menu. DOC-FLAG
non-nil means show documentation for any item that is selected by the
user. HELP-STRING-FLAG non-nil means show only the first line of the
documentation, not the full text."
(setq hui:menu-keys (hui:menu-hyperbole-prefix))
(let ((show-menu t)
(rtn)
menu-alist act-form)
(while (and show-menu (or (and menu (symbolp menu)
(setq menu-alist
(cdr (assq menu (or menu-list hui:menus)))))
(hypb:error "(hui:menu-act): Invalid menu symbol arg: `%s'"
menu)))
(cond ((and (consp (setq act-form (hui:menu-choose menu-alist doc-flag help-string-flag)))
(cdr act-form)
(symbolp (cdr act-form)))
;; Display another menu
(setq menu (cdr act-form)))
(act-form
(let ((prefix-arg current-prefix-arg))
(cond ((symbolp act-form)
(unless (eq act-form t)
(set--this-command-keys hui:menu-keys)
(setq show-menu nil
this-command act-form
rtn (call-interactively act-form))))
((stringp act-form)
(if (or doc-flag help-string-flag)
(setq show-menu nil
rtn act-form)
(hui:menu-help act-form)
;; Loop and show menu again.
))
(t (set--this-command-keys hui:menu-keys)
(setq show-menu nil
this-command act-form
rtn (eval act-form))))))
(t (setq show-menu nil))))
rtn))