emacs-diffs
[Top][All Lists]
Advanced

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

[Emacs-diffs] trunk r116781: * lisp/calendar/calendar.el (calendar-gener


From: Glenn Morris
Subject: [Emacs-diffs] trunk r116781: * lisp/calendar/calendar.el (calendar-generate-month): Apply weekend face
Date: Mon, 17 Mar 2014 16:04:39 +0000
User-agent: Bazaar (2.6b2)

------------------------------------------------------------
revno: 116781
revision-id: address@hidden
parent: address@hidden
fixes bug: http://debbugs.gnu.org/17028
committer: Glenn Morris <address@hidden>
branch nick: trunk
timestamp: Mon 2014-03-17 09:04:32 -0700
message:
  * lisp/calendar/calendar.el (calendar-generate-month): Apply weekend face
  to the right days; fixes 2013-08-06 change.
modified:
  lisp/ChangeLog                 changelog-20091113204419-o5vbwnq5f7feedwu-1432
  lisp/calendar/calendar.el      calendar.el-20091113204419-o5vbwnq5f7feedwu-478
=== modified file 'lisp/ChangeLog'
--- a/lisp/ChangeLog    2014-03-17 09:28:47 +0000
+++ b/lisp/ChangeLog    2014-03-17 16:04:32 +0000
@@ -1,3 +1,8 @@
+2014-03-17  Glenn Morris  <address@hidden>
+
+       * calendar/calendar.el (calendar-generate-month): Apply weekend
+       face to the right days; fixes 2013-08-06 change.  (Bug#17028)
+
 2014-03-17  Michael Albinus  <address@hidden>
 
        * net/tramp.el (tramp-action-out-of-band): Read pending output.

=== modified file 'lisp/calendar/calendar.el'
--- a/lisp/calendar/calendar.el 2014-01-01 07:43:34 +0000
+++ b/lisp/calendar/calendar.el 2014-03-17 16:04:32 +0000
@@ -1546,7 +1546,8 @@
          (last (calendar-last-day-of-month month year))
          (trunc (min calendar-intermonth-spacing
                      (1- calendar-left-margin)))
-         (day 1))
+         (day 1)
+         j)
    (goto-char (point-min))
    (calendar-move-to-column indent)
    (insert
@@ -1556,11 +1557,11 @@
    (calendar-insert-at-column indent calendar-intermonth-header trunc)
    ;; Use the first N characters of each day to head the columns.
    (dotimes (i 7)
+     (setq j (mod (+ calendar-week-start-day i) 7))
      (insert
       (truncate-string-to-width
-       (propertize (calendar-day-name (mod (+ calendar-week-start-day i) 7)
-                                      'header t)
-                   'font-lock-face (if (memq i '(0 6))
+       (propertize (calendar-day-name j 'header t)
+                   'font-lock-face (if (memq j '(0 6))
                                        'calendar-weekend-header
                                      'calendar-weekday-header))
        calendar-day-header-width nil ?\s)


reply via email to

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