-;;; cal-hebrew.el --- calendar functions for the Islamic calendar.
+;;; cal-hebrew.el --- calendar functions for the Hebrew calendar.
-;; Copyright (C) 1995 Free Software Foundation, Inc.
+;; Copyright (C) 1995, 1997 Free Software Foundation, Inc.
-;; Author: Nachum Dershowi <nachum@cs.uiuc.edu>
+;; Author: Nachum Dershowitz <nachum@cs.uiuc.edu>
;; Edward M. Reingold <reingold@cs.uiuc.edu>
;; Keywords: calendar
;; Human-Keywords: Hebrew calendar, calendar, diary
;; GNU General Public License for more details.
;; You should have received a copy of the GNU General Public License
-;; along with GNU Emacs; see the file COPYING. If not, write to
-;; the Free Software Foundation, 675 Mass Ave, Cambridge, MA 02139, USA.
+;; along with GNU Emacs; see the file COPYING. If not, write to the
+;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
+;; Boston, MA 02111-1307, USA.
;;; Commentary:
;; This collection of functions implements the features of calendar.el and
;; diary.el that deal with the Hebrew calendar.
+;; Technical details of all the calendrical calculations can be found in
+;; ``Calendrical Calculations'' by Nachum Dershowitz and Edward M. Reingold,
+;; Cambridge University Press (1997).
+
;; Comments, corrections, and improvements should be sent to
;; Edward M. Reingold Department of Computer Science
;; (217) 333-6733 University of Illinois at Urbana-Champaign
(calendar-dayname-on-or-before 6 (- abs-r-h 4)))
"Selichot (night)")
(list (calendar-gregorian-from-absolute (1- abs-r-h))
- "Erev Rosh HaShannah")
+ "Erev Rosh HaShanah")
(list (calendar-gregorian-from-absolute (1+ abs-r-h))
"Rosh HaShanah (second day)")
(list (calendar-gregorian-from-absolute
"Passover (seventh day)")
(list (calendar-gregorian-from-absolute (+ abs-p 7))
"Passover (eighth day)")
- (list (calendar-gregorian-from-absolute (+ abs-p 12))
+ (list (calendar-gregorian-from-absolute
+ (if (zerop (% (+ abs-p 12) 7))
+ (+ abs-p 13)
+ (+ abs-p 12)))
"Yom HaShoah")
(list (calendar-gregorian-from-absolute
(if (zerop (% abs-p 7))
(list (calendar-gregorian-from-absolute (+ abs-p 33))
"Lag BaOmer")
(list (calendar-gregorian-from-absolute (+ abs-p 43))
- "Yom Yerushalim")
+ "Yom Yerushalaim")
(list (calendar-gregorian-from-absolute (+ abs-p 49))
"Erev Shavuot")
(list (calendar-gregorian-from-absolute (+ abs-p 51))
(backward-char 1)
(subst-char-in-region date-start (point) ?\^M ?\n t)
(add-to-diary-list
- gdate (buffer-substring entry-start (point)))))))
+ gdate
+ (buffer-substring-no-properties entry-start (point))
+ (buffer-substring-no-properties
+ (1+ date-start) (1- entry-start)))))))
(setq d (cdr d))))
(setq gdate
(calendar-gregorian-from-absolute
(let*
((h-year (extract-calendar-year
(calendar-hebrew-from-absolute d)))
- (rosh-hashannah
+ (rosh-hashanah
(calendar-absolute-from-hebrew (list 7 1 h-year)))
(passover
(calendar-absolute-from-hebrew (list 1 15 h-year)))
- (rosh-hashannah-day
- (aref calendar-day-name-array (% rosh-hashannah 7)))
+ (rosh-hashanah-day
+ (aref calendar-day-name-array (% rosh-hashanah 7)))
(passover-day
(aref calendar-day-name-array (% passover 7)))
(long-h (hebrew-calendar-long-heshvan-p h-year))
(year-format
(symbol-value
(intern (format "hebrew-calendar-year-%s-%s-%s";; keviah
- rosh-hashannah-day type passover-day))))
+ rosh-hashanah-day type passover-day))))
(first-saturday;; of Hebrew year
- (calendar-dayname-on-or-before 6 (+ 6 rosh-hashannah)))
+ (calendar-dayname-on-or-before 6 (+ 6 rosh-hashanah)))
(saturday;; which Saturday of the Hebrew year
(/ (- d first-saturday) 7))
(parasha (aref year-format saturday)))