]> git.eshelyaron.com Git - emacs.git/commitdiff
(appt-disp-window): Use `calendar-set-mode-line' for a centered
authorGlenn Morris <rgm@gnu.org>
Thu, 13 May 2004 00:18:15 +0000 (00:18 +0000)
committerGlenn Morris <rgm@gnu.org>
Thu, 13 May 2004 00:18:15 +0000 (00:18 +0000)
mode-line.

Takaaki Ota  <Takaaki.Ota@am.sony.com>:
(appt-disp-window): Do not split window excessively when
`split-height-threshold' is low.

lisp/calendar/appt.el

index 002aec878cae6e253ee7697b634ef5e3919f6181..0c911ca8b7d45be7425fedec54465a245c64633a 100644 (file)
@@ -449,11 +449,10 @@ NEW-TIME is a string giving the date."
                  (same-window-p (buffer-name appt-disp-buf)))
        ;; By default, split the bottom window and use the lower part.
        (appt-select-lowest-window)
-       (split-window))
-      (pop-to-buffer appt-disp-buf))
-    (setq mode-line-format
-         (concat "-------------------- Appointment in "
-                 min-to-app " minutes. " new-time " %-"))
+        (select-window (split-window)))
+      (switch-to-buffer appt-disp-buf))
+    (calendar-set-mode-line
+     (format " Appointment in %s minutes. %s " min-to-app new-time))
     (erase-buffer)
     (insert appt-msg)
     (shrink-window-if-larger-than-buffer (get-buffer-window appt-disp-buf t))