branch: externals/hyperbole commit 8ffed95981ee22a89d48c73aae8a5a70ff60aacb Author: Bob Weiner <r...@gnu.org> Commit: Bob Weiner <r...@gnu.org>
ibut:insert-text - Fix to handle command-name arg properly --- ChangeLog | 5 +++++ hbut.el | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index ac45c6ff70..0e8c3355c5 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2024-04-10 Bob Weiner <r...@gnu.org> + +* hbut.el (ibut:insert-text): Fix when given a command-name to output proper + action button, not a nil with nil arguments. + 2024-04-09 Bob Weiner <r...@gnu.org> * hmouse-tag.el (smart-python-tag): Rewrite to just try to display a tag diff --git a/hbut.el b/hbut.el index cc2442dfc9..237910eb49 100644 --- a/hbut.el +++ b/hbut.el @@ -2647,7 +2647,8 @@ Summary of operations based on inputs (name arg from \\='hbut:current attrs): (if (<= arg2 1) "" (concat ":I" (number-to-string arg2)))))) ('nil (error "(ibut:insert-text): actype must be a Hyperbole actype or Lisp function symbol, not '%s'" orig-actype)) ;; Generic action button type - (_ (insert (format "<%s%s%s>" (actype:def-symbol actype) (if args " " "") + (_ (insert (format "<%s%s%s>" (or (actype:def-symbol actype) actype) + (if args " " "") (if args (hypb:format-args args) ""))))) (unless (looking-at "\\s-\\|\\'") (insert " "))))