diff options
author | Richard M. Stallman <rms@gnu.org> | 2002-05-29 16:36:55 +0000 |
---|---|---|
committer | Richard M. Stallman <rms@gnu.org> | 2002-05-29 16:36:55 +0000 |
commit | 8eb1dc02a11982d9d7fdc85fc2cc1f1a30586692 (patch) | |
tree | 90429bd060437682e89ed7b0601101f620237fa2 /lisp/mouse.el | |
parent | 74dde8ad92903d94199ca133b6ddadd0e302f724 (diff) | |
download | emacs-8eb1dc02a11982d9d7fdc85fc2cc1f1a30586692.tar.gz |
(mouse-set-font): Avoid misleading error message if user makes no selection.
Diffstat (limited to 'lisp/mouse.el')
-rw-r--r-- | lisp/mouse.el | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/lisp/mouse.el b/lisp/mouse.el index 01f4479465f..70fee40b53e 100644 --- a/lisp/mouse.el +++ b/lisp/mouse.el @@ -2175,11 +2175,12 @@ and selects that window." (defun mouse-set-font (&rest fonts) "Select an emacs font from a list of known good fonts and fontsets." (interactive - (and (display-multi-font-p) - (x-popup-menu - last-nonmenu-event - ;; Append list of fontsets currently defined. - (append x-fixed-font-alist (list (generate-fontset-menu)))))) + (progn (unless (display-multi-font-p) + (error "Cannot change fonts on this display")) + (x-popup-menu + last-nonmenu-event + ;; Append list of fontsets currently defined. + (append x-fixed-font-alist (list (generate-fontset-menu)))))) (if fonts (let (font) (while fonts @@ -2191,8 +2192,7 @@ and selects that window." (error (setq fonts (cdr fonts))))) (if (null font) - (error "Font not found"))) - (message "Cannot change fonts on this display"))) + (error "Font not found"))))) ;;; Bindings for mouse commands. |