From: Po Lu Date: Thu, 30 Dec 2021 11:43:58 +0000 (+0800) Subject: Make sure widget buttons always have a left box line X-Git-Tag: emacs-29.0.90~3348 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=a67b1f1944262f41e58c87f09d28858725aa5ca9;p=emacs.git Make sure widget buttons always have a left box line * lisp/wid-edit.el (widget-specify-button): Add an invisible before-string to the button overlay. (bug#51550) --- diff --git a/lisp/wid-edit.el b/lisp/wid-edit.el index a53add7d084..22f3d299081 100644 --- a/lisp/wid-edit.el +++ b/lisp/wid-edit.el @@ -437,8 +437,9 @@ the :notify function can't know the new value.") (follow-link (widget-get widget :follow-link)) (help-echo (widget-get widget :help-echo))) (widget-put widget :button-overlay overlay) - (if (functionp help-echo) + (when (functionp help-echo) (setq help-echo 'widget-mouse-help)) + (overlay-put overlay 'before-string #(" " 0 1 (invisible t))) (overlay-put overlay 'button widget) (overlay-put overlay 'keymap (widget-get widget :keymap)) (overlay-put overlay 'evaporate t)