emacs-diffs
[Top][All Lists]
Advanced

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

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


From: Juanma Barranquero
Subject: [Emacs-diffs] Changes to emacs/lisp/calendar/calendar.el,v
Date: Thu, 06 Mar 2008 15:01:24 +0000

CVSROOT:        /sources/emacs
Module name:    emacs
Changes by:     Juanma Barranquero <lektu>      08/03/06 15:01:24

Index: calendar.el
===================================================================
RCS file: /sources/emacs/emacs/lisp/calendar/calendar.el,v
retrieving revision 1.211
retrieving revision 1.212
diff -u -b -r1.211 -r1.212
--- calendar.el 8 Jan 2008 20:44:05 -0000       1.211
+++ calendar.el 6 Mar 2008 15:01:24 -0000       1.212
@@ -1676,7 +1676,7 @@
          (month (extract-calendar-month date))
          (year (extract-calendar-year date)))
     ;; (calendar-read-date t) returns a date with day = nil, which is
-    ;; not a legal date for the visible test in the diary section.
+    ;; not a valid date for the visible test in the diary section.
     (if arg (setcar (cdr date) 1))
     (increment-calendar-month month year (- calendar-offset))
     ;; Display the buffer before calling generate-calendar-window so that it
@@ -2092,7 +2092,7 @@
             font-lock-mode)
        (font-lock-fontify-buffer))
     (and mark-holidays-in-calendar
-;;;         (calendar-date-is-legal-p today) ; useful for BC dates
+;;;         (calendar-date-is-valid-p today) ; useful for BC dates
          (mark-calendar-holidays)
          (and in-calendar-window (sit-for 0)))
     (unwind-protect
@@ -2927,9 +2927,9 @@
   (let ((gap (calendar-interval
               displayed-month displayed-year
               (extract-calendar-month date) (extract-calendar-year date))))
-    (and (calendar-date-is-legal-p date) (> 2 gap) (< -2 gap))))
+    (and (calendar-date-is-valid-p date) (> 2 gap) (< -2 gap))))
 
-(defun calendar-date-is-legal-p (date)
+(defun calendar-date-is-valid-p (date)
   "Return t if DATE is a valid date."
   (let ((month (extract-calendar-month date))
         (day (extract-calendar-day date))
@@ -2945,6 +2945,9 @@
          ;; Note there are side effects on calendar navigation.
          (<= 1 year))))
 
+(define-obsolete-function-alias 'calendar-date-is-legal-p
+    'calendar-date-is-valid-p "23.1")
+
 (defun calendar-date-equal (date1 date2)
   "Return t if the DATE1 and DATE2 are the same."
   (and
@@ -2956,7 +2959,7 @@
   "Mark DATE in the calendar window with MARK.
 MARK is a single-character string, a list of face attributes/values, or a face.
 MARK defaults to `diary-entry-marker'."
-  (if (calendar-date-is-legal-p date)
+  (if (calendar-date-is-valid-p date)
       (with-current-buffer calendar-buffer
         (save-excursion
           (calendar-cursor-to-visible-date date)




reply via email to

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