diff options
| -rw-r--r-- | lisp/calendar/cal-hebrew.el | 41 |
1 files changed, 20 insertions, 21 deletions
diff --git a/lisp/calendar/cal-hebrew.el b/lisp/calendar/cal-hebrew.el index 1e97d62df0d..1f751405fa2 100644 --- a/lisp/calendar/cal-hebrew.el +++ b/lisp/calendar/cal-hebrew.el | |||
| @@ -284,27 +284,26 @@ nil if it is not visible in the current calendar window." | |||
| 284 | (if (< 9 month) (- month 9) (+ month 3)) | 284 | (if (< 9 month) (- month 9) (+ month 3)) |
| 285 | (if (< 8 month) (- month 8) (+ month 4)) | 285 | (if (< 8 month) (- month 8) (+ month 4)) |
| 286 | (if (< 7 month) (- month 7) (+ month 5)))) | 286 | (if (< 7 month) (- month 7) (+ month 5)))) |
| 287 | (let ((m1 displayed-month) | 287 | (let* ((m1 displayed-month) |
| 288 | (y1 displayed-year) | 288 | (y1 displayed-year) |
| 289 | (m2 displayed-month) | 289 | (m2 displayed-month) |
| 290 | (y2 displayed-year) | 290 | (y2 displayed-year) |
| 291 | (year)) | 291 | (start-date (progn |
| 292 | (increment-calendar-month m1 y1 -1) | 292 | (increment-calendar-month m1 y1 -1) |
| 293 | (increment-calendar-month m2 y2 1) | 293 | (calendar-absolute-from-gregorian (list m1 1 y1)))) |
| 294 | (let* ((start-date (calendar-absolute-from-gregorian | 294 | (end-date (progn |
| 295 | (list m1 1 y1))) | 295 | (increment-calendar-month m2 y2 1) |
| 296 | (end-date (calendar-absolute-from-gregorian | 296 | (calendar-absolute-from-gregorian |
| 297 | (list m2 (calendar-last-day-of-month m2 y2) y2))) | 297 | (list m2 (calendar-last-day-of-month m2 y2) y2)))) |
| 298 | (hebrew-start (calendar-hebrew-from-absolute start-date)) | 298 | (hebrew-start (calendar-hebrew-from-absolute start-date)) |
| 299 | (hebrew-end (calendar-hebrew-from-absolute end-date)) | 299 | (hebrew-end (calendar-hebrew-from-absolute end-date)) |
| 300 | (hebrew-y1 (extract-calendar-year hebrew-start)) | 300 | (hebrew-y1 (extract-calendar-year hebrew-start)) |
| 301 | (hebrew-y2 (extract-calendar-year hebrew-end))) | 301 | (hebrew-y2 (extract-calendar-year hebrew-end)) |
| 302 | (setq year (if (< 6 month) hebrew-y2 hebrew-y1)) | 302 | (year (if (< 6 month) hebrew-y2 hebrew-y1)) |
| 303 | (let ((date (calendar-gregorian-from-absolute | 303 | (date (calendar-gregorian-from-absolute |
| 304 | (calendar-absolute-from-hebrew | 304 | (calendar-absolute-from-hebrew (list month day year))))) |
| 305 | (list month day year))))) | 305 | (if (calendar-date-is-visible-p date) |
| 306 | (if (calendar-date-is-visible-p date) | 306 | (list (list date string)))))) |
| 307 | (list (list date string)))))))) | ||
| 308 | 307 | ||
| 309 | ;; h-r-h-e should be called from holidays code. | 308 | ;; h-r-h-e should be called from holidays code. |
| 310 | (declare-function holiday-filter-visible-calendar "holidays" (l)) | 309 | (declare-function holiday-filter-visible-calendar "holidays" (l)) |