;ELC ;;; compiled by rms@psilocin.gnu.ai.mit.edu on Fri Jun 28 05:52:27 1996 ;;; from file /home/fsf/rms/e19/lisp/cal-french.el ;;; emacs version 19.31.3. ;;; bytecomp version FSF 2.10 ;;; optimization is on. ;;; this file uses opcodes which do not exist in Emacs 18. (if (and (boundp 'emacs-version) (or (and (boundp 'epoch::version) epoch::version) (string-lessp emacs-version "19.29"))) (error "`cal-french.el' was compiled for Emacs 19.29 or later")) (require (quote calendar)) #@42 True if diacritical marks are available. (defvar french-calendar-accents (byte-code "À !… ÂHÚ‡" [char-table-p standard-display-table 161 [161]] 2) (#$ . 506)) #@79 Absolute date of start of French Revolutionary calendar = September 22, 1792. (defconst french-calendar-epoch (byte-code "ÀÀ‰AA@)S ‰‰@) ‰A@) ‰AA@)\f SÆ_\\ ÈVƒ] É_Ê\\Ë¥Z ‰ɦÌU…T ͦÌU?†T ΦÌU)ƒ]T-\nÏ_\\\nÉ¥\\\nÍ¥[\\\nÎ¥\\*‡" [(9 22 1792) date prior-years month day year 31 day-of-year 2 4 23 10 0 100 400 365] 5) (#$ . 674)) (byte-code "ƒÁ‚ ÂÃ\fBÅÆ\fBƒÇ‚È É\fBÇ" [french-calendar-accents ["Vendémiaire" "Brumaire" "Frimaire" "Nivôse" "Pluviôse" "Ventôse" "Germinal" "Floréal" "Prairial" "Messidor" "Thermidor" "Fructidor"] ["Vende'miaire" "Brumaire" "Frimaire" "Nivo^se" "Pluvio^se" "Vento^se" "Germinal" "Flore'al" "Prairial" "Messidor" "Thermidor" "Fructidor"] french-calendar-month-name-array current-load-list ["Primidi" "Duodi" "Tridi" "Quartidi" "Quintidi" "Sextidi" "Septidi" "Octidi" "Nonidi" "Decadi"] french-calendar-day-name-array ["de la Vertu" "du Genie" "du Labour" "de la Raison" "de la Récompense" "de la Révolution"] ["de la Vertu" "du Genie" "du Labour" "de la Raison" "de la Re'compense" "de la Re'volution"] french-calendar-special-days-array] 2) #@464 True if YEAR is a leap year on the French Revolutionary calendar. For Gregorian years 1793 to 1805, the years of actual operation of the calendar, uses historical practice based on equinoxes is followed (years 3, 7, and 11 were leap years; 15 and 20 would have been leap years). For later years uses the proposed rule of Romme (never adopted)--leap years fall every four years except century years not divisible 400 and century years that are multiples of 4000. (defalias 'french-calendar-leap-year-p #[(year) "Á>†)Â>†)ÃV…)ĦÅU…)ƦÇ>?…)ȦÅU?‡" [year (3 7 11) (15 20) 20 4 0 400 (100 200 300) 4000] 2 (#$ . 1790)]) #@191 Return last day of MONTH, YEAR on the French Revolutionary calendar. The 13th month is not really a month, but the 5 (6 in leap years) day period of `sansculottides' at the end of the year. (defalias 'french-calendar-last-day-of-month #[(month year) "ÁWƒ‡Ã\f!ƒŇƇ" [month 13 30 french-calendar-leap-year-p year 6 5] 2 (#$ . 2423)]) #@172 Compute absolute date from French Revolutionary date DATE. The absolute date is the number of days elapsed since the (imaginary) Gregorian date Sunday, December 31, 1 BC. (defalias 'calendar-absolute-from-french #[(date) "‰@)‰A@)‰AA@) SÄ_ ÅWƒ% Æ¥‚: SÆ¥ SÇ¥[\\ SÈ¥\\ SÉ¥[\\\\ SÊ_\\\n\\ S\\+‡" [date year day month 365 20 4 100 400 4000 30 french-calendar-epoch] 5 (#$ . 2769)]) #@232 Compute the French Revolutionary equivalent for absolute date DATE. The result is a list of the form (MONTH DAY YEAR). The absolute date is the number of days elapsed since the (imaginary) Gregorian date Sunday, December 31, 1 BC. (defalias 'calendar-french-from-absolute #[(date) " Wƒ ‰‰E‡ ZÃ¥‰‰ÂÇȉTE!Yƒ0 È\\T‚ *\\ ÈÂ\nÇ\nË\n \" E!VƒX È\\\nT\n‚: *T\fÇ\fÈ E!SZ \f  E,‡" [date french-calendar-epoch 0 366 approx sum y calendar-absolute-from-french 1 year m french-calendar-last-day-of-month month day] 7 (#$ . 3165)]) #@165 String of French Revolutionary date of Gregorian DATE. Returns the empty string if DATE is pre-French Revolutionary. Defaults to today's date if DATE is not given. (defalias 'calendar-french-date-string #[(&optional date) "À † ‰‰AA@)S ‰‰@) ‰A@) ‰AA@) \fSÇ_\\\fÉVƒh\fÊ_Ë\\Ì¥Z‰ʦÍU…_ΦÍU?†_ϦÍU)ƒhT- Ð_\\ Ê¥\\ Î¥[\\ Ï¥\\*!‰‰AA@)‰@)‰A@)ÕWƒ¥Ö‚è×UƒÃ؃¶Ú‚·ÛSH#‚èØƒÍÝ‚ÎÞßSÌ¥Tà\"!ȘH\"SH%,‡" [calendar-french-from-absolute date calendar-current-date prior-years month day year 31 day-of-year 2 4 23 10 0 100 400 365 french-date y m d 1 "" 13 format french-calendar-accents "Jour %s de l'Année %d de la Révolution" "Jour %s de l'Anne'e %d de la Re'volution" french-calendar-special-days-array "Décade %s, %s de %s de l'Année %d de la Révolution" "De'cade %s, %s de %s de l'Anne'e %d de la Re'volution" make-string 73 french-calendar-day-name-array french-calendar-month-name-array] 7 (#$ . 3730)]) #@73 Show the French Revolutionary calendar equivalent of the selected date. (defalias 'calendar-print-french-date #[nil "ÀÁÂ!!‰ĘƒÅÆ!‚Å !)‡" [calendar-french-date-string calendar-cursor-to-date t f "" message "Date is pre-French Revolution"] 4 (#$ . 4711) nil]) #@99 Move cursor to French Revolutionary date DATE. Echo French Revolutionary date unless NOECHO is t. (defalias 'calendar-goto-french-date #[(date &optional noecho) "ÀÁ !!!ˆ\f†Å ‡" [calendar-goto-date calendar-gregorian-from-absolute calendar-absolute-from-french date noecho calendar-print-french-date] 4 (#$ . 4980) (let* ((year (calendar-read (if french-calendar-accents "Année de la Révolution (>0): " "Anne'e de la Re'volution (>0): ") (quote (lambda (x) (> x 0))) (int-to-string (extract-calendar-year (calendar-french-from-absolute (calendar-absolute-from-gregorian (calendar-current-date))))))) (month-list (mapcar (quote list) (append french-calendar-month-name-array (if (french-calendar-leap-year-p year) (mapcar (quote (lambda (x) (concat "Jour " x))) french-calendar-special-days-array) (reverse (cdr (reverse (mapcar (quote (lambda (x) (concat "Jour " x))) french-calendar-special-days-array)))))))) (completion-ignore-case t) (month (cdr (assoc (capitalize (completing-read "Mois ou Sansculottide: " month-list nil t)) (calendar-make-alist month-list 1 (quote (lambda (x) (capitalize (car x)))))))) (decade (if (> month 12) 1 (calendar-read (if french-calendar-accents "Décade (1-3): " "De'cade (1-3): ") (quote (lambda (x) (memq x (quote (1 2 3)))))))) (day (if (> month 12) (- month 12) (calendar-read "Jour (1-10): " (quote (lambda (x) (and (<= 1 x) (<= x 10))))))) (month (if (> month 12) 13 month)) (day (+ day (* 10 (1- decade))))) (list (list month day year)))]) #@49 French calendar equivalent of date diary entry. (defalias 'diary-french-date #[nil "ÀÁÂ!!‰ĘƒÅ‚ )‡" [calendar-french-date-string calendar-cursor-to-date t f "" "Date is pre-French Revolution"] 4 (#$ . 6470)]) (provide (quote cal-french))