emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] trunk r117876: * etc/NEWS: Mention nil `calendar-mode-line


From: Christopher Schmidt
Subject: [Emacs-diffs] trunk r117876: * etc/NEWS: Mention nil `calendar-mode-line-format' will not modify
Date: Sat, 13 Sep 2014 17:48:24 +0000
User-agent: Bazaar (2.6b2)

------------------------------------------------------------
revno: 117876
revision-id: address@hidden
parent: address@hidden
fixes bug: http://debbugs.gnu.org/18467
committer: Christopher Schmidt <address@hidden>
branch nick: trunk
timestamp: Sat 2014-09-13 19:44:32 +0200
message:
  * etc/NEWS: Mention nil `calendar-mode-line-format' will not modify
  the mode line of the calendar buffer.
  * lisp/calendar/calendar.el (calendar-update-mode-line):
  Do not overwrite mode-line-format if calendar-mode-line-format is nil.
  (Bug#18467)
modified:
  etc/ChangeLog                  changelog-20091113204419-o5vbwnq5f7feedwu-1485
  etc/NEWS                       news-20100311060928-aoit31wvzf25yr1z-1
  lisp/ChangeLog                 changelog-20091113204419-o5vbwnq5f7feedwu-1432
  lisp/calendar/calendar.el      calendar.el-20091113204419-o5vbwnq5f7feedwu-478
=== modified file 'etc/ChangeLog'
--- a/etc/ChangeLog     2014-09-06 00:59:00 +0000
+++ b/etc/ChangeLog     2014-09-13 17:44:32 +0000
@@ -1,3 +1,8 @@
+2014-09-13  Christopher Schmidt  <address@hidden>
+
+       * NEWS: Mention nil `calendar-mode-line-format' will not modify
+       the mode line of the calendar buffer.  (Bug#18467)
+
 2014-09-06  Leo Liu  <address@hidden>
 
        * NEWS: Mention vector qpattern for pcase.  (Bug#18327).

=== modified file 'etc/NEWS'
--- a/etc/NEWS  2014-09-12 19:57:40 +0000
+++ b/etc/NEWS  2014-09-13 17:44:32 +0000
@@ -127,6 +127,9 @@
 *** Calendar can list and mark diary entries with Chinese dates.
 See `diary-chinese-list-entries' and `diary-chinese-mark-entries'.
 
+*** The mode line of the calendar buffer will not be modified if
+`calendar-mode-line-format' is nil.
+
 ** New ERT function `ert-summarize-tests-batch-and-exit'.
 
 ---

=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2014-09-13 16:30:21 +0000
+++ b/lisp/ChangeLog    2014-09-13 17:44:32 +0000
@@ -1,3 +1,9 @@
+2014-09-13  Christopher Schmidt  <address@hidden>
+
+       * calendar/calendar.el (calendar-update-mode-line):
+       Do not overwrite mode-line-format if calendar-mode-line-format is
+       nil.  (Bug#18467)
+
 2014-09-13  Leo Liu  <address@hidden>
 
        * emacs-lisp/pcase.el (pcase--dontwarn-upats): New var.

=== modified file 'lisp/calendar/calendar.el'
--- a/lisp/calendar/calendar.el 2014-09-08 06:03:19 +0000
+++ b/lisp/calendar/calendar.el 2014-09-13 17:44:32 +0000
@@ -1804,14 +1804,18 @@
                               nil "today"))
    '(calendar-date-string (calendar-current-date) t)
    (calendar-mode-line-entry 'calendar-scroll-left "next month" ">"))
-  "The mode line of the calendar buffer.
+  "If non-nil, the mode line of the calendar buffer.
 This is a list of items that evaluate to strings.  The elements
 are evaluated and concatenated, evenly separated by blanks.
 During evaluation, the variable `date' is available as the date
 nearest the cursor (or today's date if that fails).  To update
-the mode-line as the cursor moves, add `calendar-update-mode-line'
-to `calendar-move-hook'.  Here is an example that has the Hebrew date,
-the day number/days remaining in the year, and the ISO week/year numbers:
+the mode-line as the cursor moves, add
+`calendar-update-mode-line' to `calendar-move-hook'.
+
+If nil, do not modify the mode line at all.
+
+Here is an example that has the Hebrew date, the day number/days
+remaining in the year, and the ISO week/year numbers:
 
   (list
    \"\"
@@ -1889,7 +1893,8 @@
 
 (defun calendar-update-mode-line ()
   "Update the calendar mode line with the current date and date style."
-  (if (bufferp (get-buffer calendar-buffer))
+  (if (and calendar-mode-line-format
+           (bufferp (get-buffer calendar-buffer)))
       (with-current-buffer calendar-buffer
         (let ((start (- calendar-left-margin 2))
               (date (condition-case nil


reply via email to

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