emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] Changes to emacs/lisp/tooltip.el,v


From: Jan Djärv
Subject: [Emacs-diffs] Changes to emacs/lisp/tooltip.el,v
Date: Fri, 11 Apr 2008 06:43:45 +0000

CVSROOT:        /cvsroot/emacs
Module name:    emacs
Changes by:     Jan Djärv <jhd>        08/04/11 06:43:45

Index: tooltip.el
===================================================================
RCS file: /cvsroot/emacs/emacs/lisp/tooltip.el,v
retrieving revision 1.83
retrieving revision 1.84
diff -u -b -r1.83 -r1.84
--- tooltip.el  9 Apr 2008 09:34:06 -0000       1.83
+++ tooltip.el  11 Apr 2008 06:43:44 -0000      1.84
@@ -316,21 +316,12 @@
 (defvar tooltip-help-message nil
   "The last help message received via `tooltip-show-help'.")
 
-(defun tooltip-trunc-str (str maxlen pieces)
-  (let ((s (car pieces)))
-    (if (and pieces (< (+ (length str) (length s) 2) maxlen))
-      (tooltip-trunc-str (concat str 
-                                (if (> (length str) 0) ", "  "") 
-                                s)
-                        maxlen (cdr pieces))
-      (if (> (length str) 0) str s))))
-
 (defun tooltip-show-help-non-mode (msg)
   "Function installed as `show-help-function' when tooltip is off."
+  (let ((message-truncate-lines t))
   (message "%s" (if msg
-                   (tooltip-trunc-str "" (frame-parameter nil 'width)
-                                      (split-string msg "\n" t))
-                 "")))
+                     (replace-regexp-in-string "\n" ", " msg)
+                   ""))))
 
 (defun tooltip-show-help (msg)
   "Function installed as `show-help-function'.




reply via email to

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