emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] emacs/lisp ChangeLog tooltip.el


From: Chong Yidong
Subject: [Emacs-diffs] emacs/lisp ChangeLog tooltip.el
Date: Tue, 28 Apr 2009 02:16:57 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Chong Yidong <cyd>      09/04/28 02:16:57

Modified files:
        lisp           : ChangeLog tooltip.el 

Log message:
        * tooltip.el (tooltip-show-help): Fall back on
        tooltip-show-help-non-mode for text-only displays.

CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/ChangeLog?cvsroot=emacs&r1=1.15613&r2=1.15614
http://cvs.savannah.gnu.org/viewcvs/emacs/lisp/tooltip.el?cvsroot=emacs&r1=1.93&r2=1.94

Patches:
Index: ChangeLog
===================================================================
RCS file: /sources/emacs/emacs/lisp/ChangeLog,v
retrieving revision 1.15613
retrieving revision 1.15614
diff -u -b -r1.15613 -r1.15614
--- ChangeLog   27 Apr 2009 23:12:20 -0000      1.15613
+++ ChangeLog   28 Apr 2009 02:16:49 -0000      1.15614
@@ -1,3 +1,8 @@
+2009-04-28  Chong Yidong  <address@hidden>
+
+       * tooltip.el (tooltip-show-help): Fall back on
+       tooltip-show-help-non-mode for text-only displays.
+
 2009-04-27  Jay Belanger  <address@hidden>
 
        * calc/calc.el (calc-mode): Replace `copy-list' with `copy-sequence'.

Index: tooltip.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/tooltip.el,v
retrieving revision 1.93
retrieving revision 1.94
diff -u -b -r1.93 -r1.94
--- tooltip.el  6 Apr 2009 23:52:44 -0000       1.93
+++ tooltip.el  28 Apr 2009 02:16:56 -0000      1.94
@@ -327,7 +327,8 @@
   "The previous content of the echo area.")
 
 (defun tooltip-show-help-non-mode (help)
-  "Function installed as `show-help-function' when tooltip is off."
+  "Function installed as `show-help-function' when Tooltip mode is off.
+It is also called if Tooltip mode is on, for text-only displays."
   (when (and (not (window-minibuffer-p)) ;Don't overwrite minibuffer contents.
              (not cursor-in-echo-area))  ;Don't overwrite a prompt.
     (cond
@@ -353,6 +354,7 @@
 (defun tooltip-show-help (msg)
   "Function installed as `show-help-function'.
 MSG is either a help string to display, or nil to cancel the display."
+  (if (display-graphic-p)
   (let ((previous-help tooltip-help-message))
     (setq tooltip-help-message msg)
     (cond ((null msg)
@@ -367,7 +369,9 @@
           ;; A different help.  Remove a previous tooltip, and
           ;; display a new one, with some delay.
           (tooltip-hide)
-          (tooltip-start-delayed-tip)))))
+              (tooltip-start-delayed-tip))))
+    ;; On text-only displays, try `tooltip-show-help-non-mode'.
+    (tooltip-show-help-non-mode msg)))
 
 (defun tooltip-help-tips (event)
   "Hook function to display a help tooltip.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]