Subject: Re: bug#19174: Wishlist/suggestion for emacs/lisp/calendar/cal-french.el

From: Jean Forget <[email-masked]>
Date: Tue, 8 Jun 2021 19:47:50 +0200

Le 08/06/2021 à 11:34, Lars Ingebrigtsen a écrit :
> Jean Forget <[email-masked]> writes:
> 
>> So are you interested by a patch for version 25.1 only?
> 
> Sure.
> 
Here it is.

Jean
--- 25.1/lisp/calendar/cal-french.el	2016-09-26 23:13:06.000000000 +0200
+++ site-lisp/cal-french.el	2019-05-23 06:17:07.251961561 +0200
@@ -1,7 +1,7 @@
 ;;; cal-french.el --- calendar functions for the French Revolutionary calendar
 
-;; Copyright (C) 1988-1989, 1992, 1994-1995, 1997, 2001-2016 Free
-;; Software Foundation, Inc.
+;; Copyright (C) 1988-1989, 1992, 1994-1995, 1997, 2001-2014
+;;   Free Software Foundation, Inc.
 
 ;; Author: Edward M. Reingold <[email-masked]>
 ;; Maintainer: Glenn Morris <[email-masked]>
@@ -37,17 +37,24 @@
 
 (defconst calendar-french-month-name-array
   ["Vende'miaire" "Brumaire" "Frimaire" "Nivo^se" "Pluvio^se" "Vento^se"
-   "Germinal" "Flore'al" "Prairial" "Messidor" "Thermidor" "Fructidor"]
+   "Germinal" "Flore'al" "Prairial" "Messidor" "Thermidor" "Fructidor"
+   "jour comple'mentaire"]
   "Array of month names in the French calendar.")
 
 (defconst calendar-french-multibyte-month-name-array
   ["Vendémiaire" "Brumaire" "Frimaire" "Nivôse" "Pluviôse" "Ventôse"
-   "Germinal" "Floréal" "Prairial" "Messidor" "Thermidor" "Fructidor"]
+   "Germinal" "Floréal" "Prairial" "Messidor" "Thermidor" "Fructidor"
+   "jour complémentaire"]
   "Array of multibyte month names in the French calendar.")
 
 (defconst calendar-french-day-name-array
   ["Primidi" "Duodi" "Tridi" "Quartidi" "Quintidi" "Sextidi" "Septidi"
-   "Octidi" "Nonidi" "Decadi"]
+   "Octidi" "Nonidi" "De'cadi"]
+  "Array of day names in the French calendar.")
+
+(defconst calendar-french-multibyte-day-name-array
+  ["Primidi" "Duodi" "Tridi" "Quartidi" "Quintidi" "Sextidi" "Septidi"
+   "Octidi" "Nonidi" "Décadi"]
   "Array of day names in the French calendar.")
 
 (defconst calendar-french-special-days-array
@@ -60,6 +67,186 @@
    "de la Révolution"]
   "Array of multibyte special day names in the French calendar.")
 
+(defconst calendar-french-feasts-array
+  [;; Vendémiaire
+   "du Raisin"               "du Safran"               "de la Cha^taigne"        "de la Colchique"          "du Cheval"
+   "de la Balsamine"         "de la Carotte"           "de l'Amarante"           "du Panais"                "de la Cuve"
+   "de la Pomme de terre"    "de l'Immortelle"         "du Potiron"              "du Re'se'da"              "de l'A^ne"
+   "de la Belle de nuit"     "de la Citrouille"        "du Sarrasin"             "du Tournesol"             "du Pressoir"
+   "du Chanvre"              "de la Pe^che"            "du Navet"                "de l'Amaryllis"           "du Boeuf"
+   "de l'Aubergine"          "du Piment"               "de la Tomate"            "de l'Orge"                "du Tonneau"
+   ;; Brumaire
+   "de la Pomme"             "du Ce'leri"              "de la Poire"             "de la Betterave"          "de l'Oie"
+   "de l'He'liotrope"        "de la Figue"             "de la Scorsone`re"       "de l'Alisier"             "de la Charrue"
+   "du Salsifis"             "de la Macre"             "du Topinambour"          "de l'Endive"              "du Dindon"
+   "du Chervis"              "du Cresson"              "de la Dentelaire"        "de la Grenade"            "de la Herse"
+   "de la Bacchante"         "de l'Azerole"            "de la Garance"           "de l'Orange"              "du Faisan"
+   "de la Pistache"          "du Macjon"               "du Coing"                "du Cormier"               "du Rouleau"
+   ;; Frimaire
+   "de la Raiponce"          "du Turneps"              "de la Chicore'e"         "de la Ne`fle"             "du Cochon"
+   "de la Ma^che"            "du Chou-fleur"           "du Miel"                 "du Genie`vre"             "de la Pioche"
+   "de la Cire"              "du Raifort"              "du Ce`dre"               "du Sapin"                 "du Chevreuil"
+   "de l'Ajonc"              "du Cypre`s"              "du Lierre"               "de la Sabine"             "du Hoyau"
+   "de l'E'rable-sucre"      "de la Bruye`re"          "du Roseau"               "de l'Oseille"             "du Grillon"
+   "du Pignon"               "du Lie`ge"               "de la Truffe"            "de l'Olive"               "de la Pelle"
+   ;; Nivôse
+   "de la Tourbe"            "de la Houille"           "du Bitume"               "du Soufre"                "du Chien"
+   "de la Lave"              "de la Terre ve'ge'tale"  "du Fumier"               "du Salpe^tre"             "du Fle'au"
+   "du Granit"               "de l'Argile"             "de l'Ardoise"            "du Gre`s"                 "du Lapin"
+   "du Silex"                "de la Marne"             "de la Pierre a` chaux"   "du Marbre"                "du Van"
+   "de la Pierre a` pla^tre" "du Sel"                  "du Fer"                  "du Cuivre"                "du Chat"
+   "de l'E'tain"             "du Plomb"                "du Zinc"                 "du Mercure"               "du Crible"
+   ;; Pluviôse
+   "de la Laure'ole"         "de la Mousse"            "du Fragon"               "du Perce-neige"           "du Taureau"
+   "du Laurier-thym"         "de l'Amadouvier"         "du Me'ze're'on"          "du Peuplier"              "de la Cogne'e"
+   "de l'Elle'bore"          "du Brocoli"              "du Laurier"              "de l'Avelinier"           "de la Vache"
+   "du Buis"                 "du Lichen"               "de l'If"                 "de la Pulmonaire"         "de la Serpette"
+   "du Thlaspi"              "du Thymele'"             "du Chiendent"            "de la Trai^nasse"         "du Lie`vre"
+   "de la Gue`de"            "du Noisetier"            "du Cyclamen"             "de la Che'lidoine"        "du Trai^neau"
+   ;; Ventôse
+   "du Tussilage"            "du Cornouiller"          "du Violier"              "du Troe`ne"               "du Bouc"
+   "de l'Asaret"             "de l'Alaterne"           "de la Violette"          "du Marsault"              "de la Be^che"
+   "du Narcisse"             "de l'Orme"               "de la Fumeterre"         "du Ve'lar"                "de la Che`vre"
+   "de l'E'pinard"           "du Doronic"              "du Mouron"               "du Cerfeuil"              "du Cordeau"
+   "de la Mandragore"        "du Persil"               "du Cochle'aria"          "de la Pa^querette"        "du Thon"
+   "du Pissenlit"            "de la Sylvie"            "du Capillaire"           "du Fre^ne"                "du Plantoir"
+   ;; Germinal
+   "de la Primeve`re"        "du Platane"              "de l'Asperge"            "de la Tulipe"             "de la Poule"
+   "de la Blette"            "du Bouleau"              "de la Jonquille"         "de l'Aulne"               "du Couvoir"
+   "de la Pervenche"         "du Charme"               "de la Morille"           "du He^tre"                "de l'Abeille"
+   "de la Laitue"            "du Me'le`ze"             "de la Cigue\""           "du Radis"                 "de la Ruche"
+   "du Gainier"              "de la Romaine"           "du Marronnier"           "de la Roquette"           "du Pigeon"
+   "du Lilas"                "de l'Ane'mone"           "de la Pense'e"           "de la Myrtille"           "du Greffoir"
+   ;; Floréal
+   "de la Rose"              "du Che^ne"               "de la Fouge`re"          "de l'Aube'pine"           "du Rossignol"
+   "de l'Ancolie"            "du Muguet"               "du Champignon"           "de la Jacinthe"           "du Rateau"
+   "de la Rhubarbe"          "du Sainfoin"             "du Ba^ton-d'or"          "du Chame'risier"          "du Ver a` soie"
+   "de la Consoude"          "de la Pimprenelle"       "de la Corbeille-d'or"    "de l'Arroche"             "du Sarcloir"
+   "du Statice"              "de la Fritillaire"       "de la Bourrache"         "de la Vale'riane"         "de la Carpe"
+   "du Fusain"               "de la Civette"           "de la Buglosse"          "du Se'neve'"              "de la Houlette"
+   ;; Prairial
+   "de la Luzerne"           "de l'He'me'rocalle"      "du Tre`fle"              "de l'Ange'lique"          "du Canard"
+   "de la Me'lisse"          "du Fromental"            "du Martagon"             "du Serpolet"              "de la Faux"
+   "de la Fraise"            "de la Be'toine"          "du Pois"                 "de l'Acacia"              "de la Caille"
+   "de l'Oeillet"            "du Sureau"               "du Pavot"                "du Tilleul"               "de la Fourche"
+   "du Barbeau"              "de la Camomille"         "du Che`vrefeuille"       "du Caille-lait"           "de la Tanche"
+   "du Jasmin"               "de la Verveine"          "du Thym"                 "de la Pivoine"            "du Chariot"
+   ;; Messidor
+   "du Seigle"               "de l'Avoine"             "de l'Oignon"             "de la Ve'ronique"         "du Mulet"
+   "du Romarin"              "du Concombre"            "de l'E'chalotte"         "de l'Absinthe"            "de la Faucille"
+   "de la Coriandre"         "de l'Artichaut"          "de la Girofle'e"         "de la Lavande"            "du Chamois"
+   "du Tabac"                "de la Groseille"         "de la Gesse"             "de la Cerise"             "du Parc"
+   "de la Menthe"            "du Cumin"                "du Haricot"              "de l'Orcane`te"           "de la Pintade"
+   "de la Sauge"             "de l'Ail"                "de la Vesce"             "du Ble'"                  "de la Chale'mie"
+   ;; Thermidor
+   "de l'E'pautre"           "du Bouillon-blanc"       "du Melon"                "de l'Ivraie"              "du Be'lier"
+   "de la Pre`le"            "de l'Armoise"            "du Carthame"             "de la Mu^re"              "de l'Arrosoir"
+   "du Panis"                "du Salicor"              "de l'Abricot"            "du Basilic"               "de la Brebis"
+   "de la Guimauve"          "du Lin"                  "de l'Amande"             "de la Gentiane"           "de l'E'cluse"
+   "de la Carline"           "du Ca^prier"             "de la Lentille"          "de l'Aune'e"              "de la Loutre"
+   "de la Myrte"             "du Colza"                "du Lupin"                "du Coton"                 "du Moulin"
+   ;; Fructidor
+   "de la Prune"             "du Millet"               "du Lycoperdon"           "de l'Escourgeon"          "du Saumon"
+   "de la Tube'reuse"        "du Sucrion"              "de l'Apocyn"             "de la Re'glisse"          "de l'E'chelle"
+   "de la Paste`que"         "du Fenouil"              "de l'E'pine-vinette"     "de la Noix"               "de la Truite"
+   "du Citron"               "de la Carde`re"          "du Nerprun"              "du Tagette"               "de la Hotte"
+   "de l'E'glantier"         "de la Noisette"          "du Houblon"              "du Sorgho"                "de l'E'crevisse"
+   "de la Bagarade"          "de la Verge-d'or"        "du Mai\"s"               "du Marron"                "du Panier"
+   ;; jour complémentaire
+   "de la Vertu"             "du Ge'nie"               "du Travail"              "de la Raison"             "des Re'compenses"
+   "de la Re'volution"]
+  "Array of day feasts in the French calendar.")
+
+(defconst calendar-french-multibyte-feasts-array
+  [;; Vendémiaire
+   "du Raisin"             "du Safran"             "de la Châtaigne"       "de la Colchique"        "du Cheval"
+   "de la Balsamine"       "de la Carotte"         "de l'Amarante"         "du Panais"              "de la Cuve"
+   "de la Pomme de terre"  "de l'Immortelle"       "du Potiron"            "du Réséda"              "de l'Âne"
+   "de la Belle de nuit"   "de la Citrouille"      "du Sarrasin"           "du Tournesol"           "du Pressoir"
+   "du Chanvre"            "de la Pêche"           "du Navet"              "de l'Amaryllis"         "du Bœuf"
+   "de l'Aubergine"        "du Piment"             "de la Tomate"          "de l'Orge"              "du Tonneau"
+   ;; Brumaire
+   "de la Pomme"           "du Céleri"             "de la Poire"           "de la Betterave"        "de l'Oie"
+   "de l'Héliotrope"       "de la Figue"           "de la Scorsonère"      "de l'Alisier"           "de la Charrue"
+   "du Salsifis"           "de la Macre"           "du Topinambour"        "de l'Endive"            "du Dindon"
+   "du Chervis"            "du Cresson"            "de la Dentelaire"      "de la Grenade"          "de la Herse"
+   "de la Bacchante"       "de l'Azerole"          "de la Garance"         "de l'Orange"            "du Faisan"
+   "de la Pistache"        "du Macjon"             "du Coing"              "du Cormier"             "du Rouleau"
+   ;; Frimaire
+   "de la Raiponce"        "du Turneps"            "de la Chicorée"        "de la Nèfle"            "du Cochon"
+   "de la Mâche"           "du Chou-fleur"         "du Miel"               "du Genièvre"            "de la Pioche"
+   "de la Cire"            "du Raifort"            "du Cèdre"              "du Sapin"               "du Chevreuil"
+   "de l'Ajonc"            "du Cyprès"             "du Lierre"             "de la Sabine"           "du Hoyau"
+   "de l'Érable-sucre"     "de la Bruyère"         "du Roseau"             "de l'Oseille"           "du Grillon"
+   "du Pignon"             "du Liège"              "de la Truffe"          "de l'Olive"             "de la Pelle"
+   ;; Nivôse
+   "de la Tourbe"          "de la Houille"         "du Bitume"             "du Soufre"              "du Chien"
+   "de la Lave"            "de la Terre végétale"  "du Fumier"             "du Salpêtre"            "du Fléau"
+   "du Granit"             "de l'Argile"           "de l'Ardoise"          "du Grès"                "du Lapin"
+   "du Silex"              "de la Marne"           "de la Pierre à chaux"  "du Marbre"              "du Van"
+   "de la Pierre à plâtre" "du Sel"                "du Fer"                "du Cuivre"              "du Chat"
+   "de l'Étain"            "du Plomb"              "du Zinc"               "du Mercure"             "du Crible"
+   ;; Pluviôse
+   "de la Lauréole"        "de la Mousse"          "du Fragon"             "du Perce-neige"         "du Taureau"
+   "du Laurier-thym"       "de l'Amadouvier"       "du Mézéréon"           "du Peuplier"            "de la Cognée"
+   "de l'Ellébore"         "du Brocoli"            "du Laurier"            "de l'Avelinier"         "de la Vache"
+   "du Buis"               "du Lichen"             "de l'If"               "de la Pulmonaire"       "de la Serpette"
+   "du Thlaspi"            "du Thymelé"            "du Chiendent"          "de la Traînasse"        "du Lièvre"
+   "de la Guède"           "du Noisetier"          "du Cyclamen"           "de la Chélidoine"       "du Traîneau"
+   ;; Ventôse
+   "du Tussilage"          "du Cornouiller"        "du Violier"            "du Troène"              "du Bouc"
+   "de l'Asaret"           "de l'Alaterne"         "de la Violette"        "du Marsault"            "de la Bêche"
+   "du Narcisse"           "de l'Orme"             "de la Fumeterre"       "du Vélar"               "de la Chèvre"
+   "de l'Épinard"          "du Doronic"            "du Mouron"             "du Cerfeuil"            "du Cordeau"
+   "de la Mandragore"      "du Persil"             "du Cochléaria"         "de la Pâquerette"       "du Thon"
+   "du Pissenlit"          "de la Sylvie"          "du Capillaire"         "du Frêne"               "du Plantoir"
+   ;; Germinal
+   "de la Primevère"       "du Platane"            "de l'Asperge"          "de la Tulipe"           "de la Poule"
+   "de la Blette"          "du Bouleau"            "de la Jonquille"       "de l'Aulne"             "du Couvoir"
+   "de la Pervenche"       "du Charme"             "de la Morille"         "du Hêtre"               "de l'Abeille"
+   "de la Laitue"          "du Mélèze"             "de la Ciguë"           "du Radis"               "de la Ruche"
+   "du Gainier"            "de la Romaine"         "du Marronnier"         "de la Roquette"         "du Pigeon"
+   "du Lilas"              "de l'Anémone"          "de la Pensée"          "de la Myrtille"         "du Greffoir"
+   ;; Floréal
+   "de la Rose"            "du Chêne"              "de la Fougère"         "de l'Aubépine"          "du Rossignol"
+   "de l'Ancolie"          "du Muguet"             "du Champignon"         "de la Jacinthe"         "du Rateau"
+   "de la Rhubarbe"        "du Sainfoin"           "du Bâton-d'or"         "du Chamérisier"         "du Ver à soie"
+   "de la Consoude"        "de la Pimprenelle"     "de la Corbeille-d'or"  "de l'Arroche"           "du Sarcloir"
+   "du Statice"            "de la Fritillaire"     "de la Bourrache"       "de la Valériane"        "de la Carpe"
+   "du Fusain"             "de la Civette"         "de la Buglosse"        "du Sénevé"              "de la Houlette"
+   ;; Prairial
+   "de la Luzerne"         "de l'Hémérocalle"      "du Trèfle"             "de l'Angélique"         "du Canard"
+   "de la Mélisse"         "du Fromental"          "du Martagon"           "du Serpolet"            "de la Faux"
+   "de la Fraise"          "de la Bétoine"         "du Pois"               "de l'Acacia"            "de la Caille"
+   "de l'Œillet"           "du Sureau"             "du Pavot"              "du Tilleul"             "de la Fourche"
+   "du Barbeau"            "de la Camomille"       "du Chèvrefeuille"      "du Caille-lait"         "de la Tanche"
+   "du Jasmin"             "de la Verveine"        "du Thym"               "de la Pivoine"          "du Chariot"
+   ;; Messidor
+   "du Seigle"             "de l'Avoine"           "de l'Oignon"           "de la Véronique"        "du Mulet"
+   "du Romarin"            "du Concombre"          "de l'Échalotte"        "de l'Absinthe"          "de la Faucille"
+   "de la Coriandre"       "de l'Artichaut"        "de la Giroflée"        "de la Lavande"          "du Chamois"
+   "du Tabac"              "de la Groseille"       "de la Gesse"           "de la Cerise"           "du Parc"
+   "de la Menthe"          "du Cumin"              "du Haricot"            "de l'Orcanète"          "de la Pintade"
+   "de la Sauge"           "de l'Ail"              "de la Vesce"           "du Blé"                 "de la Chalémie"
+   ;; Thermidor
+   "de l'Épautre"          "du Bouillon-blanc"     "du Melon"              "de l'Ivraie"            "du Bélier"
+   "de la Prèle"           "de l'Armoise"          "du Carthame"           "de la Mûre"             "de l'Arrosoir"
+   "du Panis"              "du Salicor"            "de l'Abricot"          "du Basilic"             "de la Brebis"
+   "de la Guimauve"        "du Lin"                "de l'Amande"           "de la Gentiane"         "de l'Écluse"
+   "de la Carline"         "du Câprier"            "de la Lentille"        "de l'Aunée"             "de la Loutre"
+   "de la Myrte"           "du Colza"              "du Lupin"              "du Coton"               "du Moulin"
+   ;; Fructidor
+   "de la Prune"           "du Millet"             "du Lycoperdon"         "de l'Escourgeon"        "du Saumon"
+   "de la Tubéreuse"       "du Sucrion"            "de l'Apocyn"           "de la Réglisse"         "de l'Échelle"
+   "de la Pastèque"        "du Fenouil"            "de l'Épine-vinette"    "de la Noix"             "de la Truite"
+   "du Citron"             "de la Cardère"         "du Nerprun"            "du Tagette"             "de la Hotte"
+   "de l'Églantier"        "de la Noisette"        "du Houblon"            "du Sorgho"              "de l'Écrevisse"
+   "de la Bagarade"        "de la Verge-d'or"      "du Maïs"               "du Marron"              "du Panier"
+   ;; jour complémentaire
+   "de la Vertu"           "du Génie"              "du Travail"            "de la Raison"           "des Récompenses"
+   "de la Révolution"]
+  "Array of multibyte day feasts in the French calendar.")
+
 (defun calendar-french-accents-p ()
   "Return non-nil if diacritical marks are available."
   (and (or window-system
@@ -76,7 +263,9 @@
 
 (defun calendar-french-day-name-array ()
   "Return the array of day names."
-  calendar-french-day-name-array)
+  (if (calendar-french-accents-p)
+      calendar-french-multibyte-day-name-array
+  calendar-french-day-name-array))
 
 (defun calendar-french-special-days-array ()
   "Return the special day names, depending on whether accents are available."
@@ -84,6 +273,23 @@
       calendar-french-multibyte-special-days-array
     calendar-french-special-days-array))
 
+(defun calendar-french-feasts-array ()
+  "Return the day feasts, depending on whether accents are available."
+  (if (calendar-french-accents-p)
+      calendar-french-multibyte-feasts-array
+    calendar-french-feasts-array))
+
+(defun calendar-french-trim-feast (feast)
+  "Remove the article from the feast, e.g. \"du Raisin\" -> \"Raisin\"
+or \"de la Vertu\" -> \"Vertu\""
+  (cond
+     ((equal (substring feast 0 3) "du ")    (substring feast 3))
+     ((equal (substring feast 0 6) "de la ") (substring feast 6))
+     ((equal (substring feast 0 5) "de l'")  (substring feast 5))
+     ((equal (substring feast 0 4) "des ")   (substring feast 4))
+     (t feast))
+)
+
 (defun calendar-french-leap-year-p (year)
   "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
@@ -171,18 +377,15 @@
          (d (calendar-extract-day french-date)))
     (cond
      ((< y 1) "")
-     ((= m 13) (format (if (calendar-french-accents-p)
-                           "Jour %s de l'Année %d de la Révolution"
-                         "Jour %s de l'Anne'e %d de la Re'volution")
-                       (aref (calendar-french-special-days-array) (1- d))
-                       y))
      (t (format
          (if (calendar-french-accents-p)
-             "%d %s an %d de la Révolution"
-           "%d %s an %d de la Re'volution")
+             "%s %d %s an %d de la Révolution, jour %s"
+           "%s %d %s an %d de la Re'volution, jour %s")
+         (aref (calendar-french-day-name-array) (% (1- d) 10))
          d
          (aref (calendar-french-month-name-array) (1- m))
-         y)))))
+         y
+         (aref (calendar-french-feasts-array) (+ -31 (* 30 m) d)) )))))
 
 ;;;###cal-autoload
 (defun calendar-french-print-date ()
@@ -199,7 +402,7 @@
 Echo French Revolutionary date unless NOECHO is non-nil."
   (interactive
    (let* ((months (calendar-french-month-name-array))
-          (special-days (calendar-french-special-days-array))
+          (feasts (calendar-french-feasts-array))
           (year (progn
                   (calendar-read
                    (if (calendar-french-accents-p)
@@ -215,29 +418,35 @@
            (mapcar 'list
                    (append months
                            (if (calendar-french-leap-year-p year)
-                               (mapcar
-                                (lambda (x) (concat "Jour " x))
-                                calendar-french-special-days-array)
+                               (mapcar 'calendar-french-trim-feast
+                                feasts)
                              (reverse
                               (cdr ; we don't want rev. day in a non-leap yr
                                (reverse
-                                (mapcar
-                                 (lambda (x)
-                                   (concat "Jour " x))
-                                 special-days))))))))
+                                (mapcar 'calendar-french-trim-feast
+                                 feasts))))))))
           (completion-ignore-case t)
+          (month-prompt (if (calendar-french-accents-p)
+                        "Mois ou \"jour complémentaire\" ou fête: "
+                        "Mois ou \"jour comple'mentaire\" ou fe^te: "))
           (month (cdr (assoc-string
                        (completing-read
-                        "Mois ou Sansculottide: "
+                        month-prompt
                         month-list
                         nil t)
                        (calendar-make-alist month-list 1 'car) t)))
-          (day (if (> month 12)
-                   (- month 12)
+          (last-day (if (> month 13) (calendar-french-last-day-of-month 13 year)
+                         (calendar-french-last-day-of-month month year)))
+          (day (if (> month 13)
+                   (- month 13)
                  (calendar-read
-                  "Jour (1-30): "
-                  (lambda (x) (and (<= 1 x) (<= x 30))))))
-          (month (if (> month 12) 13 month)))
+                  (format "Jour (1-%d): " last-day)
+                  (lambda (x) (and (<= 1 x) (<= x last-day))))))
+          (month (if (> month 13) 1 month))) ; all days in Vendémiaire and numbered 1 to 365
+                                             ; e.g., "Pomme" gives 31 Vendémiaire automatically normalized to 1 Brumaire
+                                             ; "Céleri" gives 32 Vnd normalized to 2 Bru,
+                                             ; "Raiponce" gives 61 Vnd normalized to 1 Frimaire, etc
+                                             ; until "Récompences" which gives 365 Vnd normalized to 5 jour complémentaire
      (list (list month day year))))
   (calendar-goto-date (calendar-gregorian-from-absolute
                        (calendar-french-to-absolute date)))
@@ -256,4 +465,8 @@
 
 (provide 'cal-french)
 
+;; Local Variables:
+;; coding: utf-8
+;; End:
+
 ;;; cal-french.el ends here