changeset 34540:e1e4704de6ed

(tooltip-show): If an error is signaled in x-show-tip, display that error, and display the help in the echo area.
author Gerd Moellmann <gerd@gnu.org>
date Thu, 14 Dec 2000 10:35:22 +0000
parents ed447b1eada2
children 99cd5704dacb
files lisp/tooltip.el
diffstat 1 files changed, 12 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/tooltip.el	Thu Dec 14 05:44:18 2000 +0000
+++ b/lisp/tooltip.el	Thu Dec 14 10:35:22 2000 +0000
@@ -308,12 +308,18 @@
   "Show a tooltip window at the current mouse position displaying TEXT."
   (if tooltip-use-echo-area
       (message "%s" text)
-    (x-show-tip text
-		(selected-frame)
-		tooltip-frame-parameters
-		nil
-		tooltip-x-offset
-		tooltip-y-offset)))
+    (condition-case error
+	(x-show-tip text
+		    (selected-frame)
+		    tooltip-frame-parameters
+		    nil
+		    tooltip-x-offset
+		    tooltip-y-offset)
+      (error 
+       (message "Error while displaying tooltip: %s" error)
+       (sit-for 1)
+       (message "%s" text)))))
+
 
 (defun tooltip-hide (&optional ignored-arg)
   "Hide a tooltip, if one is displayed.