bug-gcal
[Top][All Lists]
Advanced

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

[Bug-gcal] [patch-gcal] add Public holidays in Austria


From: bw1
Subject: [Bug-gcal] [patch-gcal] add Public holidays in Austria
Date: Sun, 22 Jul 2018 23:21:44 +0200
User-agent: Mutt/1.10.1 (2018-07-13)

---
 src/hd-data.c  |  15 ++++-
 src/hd-data2.c | 183 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++-
 src/hd-data2.h |  54 +++++++++++++++++
 src/hd-defs.h  |   4 ++
 4 files changed, 254 insertions(+), 2 deletions(-)

diff --git a/src/hd-data.c b/src/hd-data.c
index 1996313..b0b9915 100644
--- a/src/hd-data.c
+++ b/src/hd-data.c
@@ -97,6 +97,15 @@ const Cc_struct cc_holidays[] = {
   {"AR", N_("Argentina"), ar_hdy},
   {"AS", N_("American Samoa"), as_hdy},
   {"AT", N_("Austria"), at_hdy},
+  {"AT_B", N_("Austria/Burgenland"), at_bu_hdy},
+  {"AT_K", N_("Austria/Carinthia"), at_ka_hdy},
+  {"AT_NO", N_("Austria/Lower Austria"), at_no_hdy},
+  {"AT_OO", N_("Austria/Upper Austria"), at_oo_hdy},
+  {"AT_S", N_("Austria/Salzburg"), at_sa_hdy},
+  {"AT_ST", N_("Austria/Styria"), at_st_hdy},
+  {"AT_T", N_("Austria/Tyrol"), at_ti_hdy},
+  {"AT_V", N_("Austria/Vorarlberg"), at_vo_hdy},
+  {"AT_W", N_("Austria/Vienna"), at_wi_hdy},
   {"AU_CT", N_("Australia/Canberra"), au_ct_hdy},
   {"AU_NT", N_("Australia/Northern Territory"), au_nt_hdy},
   {"AU_QU", N_("Australia/Queensland"), au_qu_hdy},
@@ -1015,7 +1024,11 @@ const Ht_struct hd_text[] = {
   {HD_WHITSUN_EVE, N_("Whitsun Eve")},
   {HD_W_TUBMANS_BIRTHDAY, N_("W. Tubman's Birthday")},
   {HD_YAP_DAY, N_("Yap Day")},
-  {HD_DAY_OF_CZECH_STATEHOOD, N_("Day of Czech Statehood")}
+  {HD_DAY_OF_CZECH_STATEHOOD, N_("Day of Czech Statehood")},
+  {HD_DAY_OF_THE_REFERENDUM, N_("Day of the referendum")},
+  {HD_SAINT_FLORIAN, N_("Saint Florian")},
+  {HD_RUPERT_OF_SALZBURG, N_("Rupert of Salzburg")},
+  {HD_SAINT_LEOPOLD_III, N_("Saint Leopold III")}
 #endif /* !HD_TOP20CC */
 };
 
diff --git a/src/hd-data2.c b/src/hd-data2.c
index 567f9a2..c624265 100644
--- a/src/hd-data2.c
+++ b/src/hd-data2.c
@@ -793,6 +793,9 @@ at_hdy (init_data, detected, easter, year, hd_elems, fday, 
count)
   holiday (*init_data, detected,
           _(hd_text[HD_FEAST_OF_CORPUS_CHRISTI].ht_text), ptr_cc_id, "+",
           easter + 60, 0, year, hd_elems, fday, count);
+  holiday (*init_data, detected, _(hd_text[HD_ASH_WEDNESDAY].ht_text),
+          ptr_cc_id, DIS_HLS_PREF, easter - 46, 0, year, hd_elems, fday,
+          count);
   holiday (*init_data, detected, _(hd_text[HD_GOOD_FRIDAY].ht_text),
           ptr_cc_id, DIS_HLS_PREF2, easter - 2, 0, year, hd_elems, fday,
           count);
@@ -805,8 +808,11 @@ at_hdy (init_data, detected, easter, year, hd_elems, fday, 
count)
           8, MONTH_MAX, year, hd_elems, fday, count);
   holiday (*init_data, detected, _(hd_text[HD_NATIONAL_HOLIDAY].ht_text),
           ptr_cc_id, "+", 26, 10, year, hd_elems, fday, count);
+  holiday (*init_data, detected, _(hd_text[HD_CHRISTMAS_EVE].ht_text),
+          ptr_cc_id, DIS_HLS_PREF2, 24, MONTH_MAX, year, hd_elems, fday,
+          count);
   holiday (*init_data, detected, _(hd_text[HD_SYLVESTER].ht_text), ptr_cc_id,
-          DIS_HLS_PREF, dvec[MONTH_MAX - 1], MONTH_MAX, year, hd_elems, fday,
+          DIS_HLS_PREF2, dvec[MONTH_MAX - 1], MONTH_MAX, year, hd_elems, fday,
           count);
   holiday (*init_data, detected, _(hd_text[HD_THREE_KINGS_DAY].ht_text),
           ptr_cc_id, "+", 6, MONTH_MIN, year, hd_elems, fday, count);
@@ -814,6 +820,181 @@ at_hdy (init_data, detected, easter, year, hd_elems, 
fday, count)
                      count, ptr_cc_id);
 }
 
+void
+at_vo_hdy (init_data, detected, easter, year, hd_elems, fday, count)
+     Bool *init_data;
+     const Bool detected;
+     int easter;
+     const int year;
+     int *hd_elems;
+     const int fday;
+     const int count;
+/*!
+   Manages all specific holidays celebrated in Austria/Vorarlberg.
+*/
+{
+  at_hdy (init_data, detected, easter, year, hd_elems, fday, count);
+  ptr_cc_id = "AT_V";
+  holiday (*init_data, detected, _(hd_text[HD_ST_JOSEPHS_DAY].ht_text),
+     ptr_cc_id, "#", 19, 3, year, hd_elems, fday, count);
+}
+
+void
+at_ti_hdy (init_data, detected, easter, year, hd_elems, fday, count)
+     Bool *init_data;
+     const Bool detected;
+     int easter;
+     const int year;
+     int *hd_elems;
+     const int fday;
+     const int count;
+/*!
+   Manages all specific holidays celebrated in Austria/Tyrol.
+*/
+{
+  at_hdy (init_data, detected, easter, year, hd_elems, fday, count);
+  ptr_cc_id = "AT_T";
+  holiday (*init_data, detected, _(hd_text[HD_ST_JOSEPHS_DAY].ht_text),
+     ptr_cc_id, "#", 19, 3, year, hd_elems, fday, count);
+}
+
+void
+at_st_hdy (init_data, detected, easter, year, hd_elems, fday, count)
+     Bool *init_data;
+     const Bool detected;
+     int easter;
+     const int year;
+     int *hd_elems;
+     const int fday;
+     const int count;
+/*!
+   Manages all specific holidays celebrated in Austria/Styria.
+*/
+{
+  at_hdy (init_data, detected, easter, year, hd_elems, fday, count);
+  ptr_cc_id = "AT_ST";
+  holiday (*init_data, detected, _(hd_text[HD_ST_JOSEPHS_DAY].ht_text),
+     ptr_cc_id, "#", 19, 3, year, hd_elems, fday, count);
+}
+
+void
+at_ka_hdy (init_data, detected, easter, year, hd_elems, fday, count)
+     Bool *init_data;
+     const Bool detected;
+     int easter;
+     const int year;
+     int *hd_elems;
+     const int fday;
+     const int count;
+/*!
+   Manages all specific holidays celebrated in Austria/Carinthia.
+*/
+{
+  at_hdy (init_data, detected, easter, year, hd_elems, fday, count);
+  ptr_cc_id = "AT_K";
+  holiday (*init_data, detected, _(hd_text[HD_ST_JOSEPHS_DAY].ht_text),
+     ptr_cc_id, "#", 19, 3, year, hd_elems, fday, count);
+  // Tag der Volksabstimmung 
https://en.wikipedia.org/wiki/Carinthian_plebiscite,_1920
+  holiday (*init_data, detected, _(hd_text[HD_DAY_OF_THE_REFERENDUM].ht_text),
+     ptr_cc_id, "#", 10, 10, year, hd_elems, fday, count);
+}
+
+void
+at_oo_hdy (init_data, detected, easter, year, hd_elems, fday, count)
+     Bool *init_data;
+     const Bool detected;
+     int easter;
+     const int year;
+     int *hd_elems;
+     const int fday;
+     const int count;
+/*!
+   Manages all specific holidays celebrated in Austria/Upper Austria.
+*/
+{
+  at_hdy (init_data, detected, easter, year, hd_elems, fday, count);
+  ptr_cc_id = "AT_OO";
+  if (year >= 2004)
+    holiday (*init_data, detected, _(hd_text[HD_SAINT_FLORIAN].ht_text),
+       ptr_cc_id, "#", 4, 5, year, hd_elems, fday, count);
+}
+
+void
+at_bu_hdy (init_data, detected, easter, year, hd_elems, fday, count)
+     Bool *init_data;
+     const Bool detected;
+     int easter;
+     const int year;
+     int *hd_elems;
+     const int fday;
+     const int count;
+/*!
+   Manages all specific holidays celebrated in Austria/Burgenland
+*/
+{
+  at_hdy (init_data, detected, easter, year, hd_elems, fday, count);
+  ptr_cc_id = "AT_B";
+  holiday (*init_data, detected, _(hd_text[HD_MARTINIMAS].ht_text),
+     ptr_cc_id, "#", 11, 11, year, hd_elems, fday, count);
+}
+
+void
+at_no_hdy (init_data, detected, easter, year, hd_elems, fday, count)
+     Bool *init_data;
+     const Bool detected;
+     int easter;
+     const int year;
+     int *hd_elems;
+     const int fday;
+     const int count;
+/*!
+   Manages all specific holidays celebrated in Austria/Lower Austria
+*/
+{
+  at_hdy (init_data, detected, easter, year, hd_elems, fday, count);
+  ptr_cc_id = "AT_NO";
+  holiday (*init_data, detected, _(hd_text[HD_SAINT_LEOPOLD_III].ht_text),
+     ptr_cc_id, "#", 15, 11, year, hd_elems, fday, count);
+}
+
+void
+at_wi_hdy (init_data, detected, easter, year, hd_elems, fday, count)
+     Bool *init_data;
+     const Bool detected;
+     int easter;
+     const int year;
+     int *hd_elems;
+     const int fday;
+     const int count;
+/*!
+   Manages all specific holidays celebrated in Austria/Vienna
+*/
+{
+  at_hdy (init_data, detected, easter, year, hd_elems, fday, count);
+  ptr_cc_id = "AT_W";
+  holiday (*init_data, detected, _(hd_text[HD_SAINT_LEOPOLD_III].ht_text),
+     ptr_cc_id, "#", 15, 11, year, hd_elems, fday, count);
+}
+
+void
+at_sa_hdy (init_data, detected, easter, year, hd_elems, fday, count)
+     Bool *init_data;
+     const Bool detected;
+     int easter;
+     const int year;
+     int *hd_elems;
+     const int fday;
+     const int count;
+/*!
+   Manages all specific holidays celebrated in Austria/Salzburg
+*/
+{
+  at_hdy (init_data, detected, easter, year, hd_elems, fday, count);
+  ptr_cc_id = "AT_S";
+  holiday (*init_data, detected, _(hd_text[HD_RUPERT_OF_SALZBURG].ht_text),
+     ptr_cc_id, "#", 24, 9, year, hd_elems, fday, count);
+}
+
 
 
 void
diff --git a/src/hd-data2.h b/src/hd-data2.h
index d791e66..e2563fc 100644
--- a/src/hd-data2.h
+++ b/src/hd-data2.h
@@ -136,6 +136,60 @@ extern void
                int easter,
                const int year,
                int *hd_elems, const int fday, const int count));
+extern void
+  at_vo_hdy __P_ ((Bool * init_data,
+               const Bool detected,
+               int easter,
+               const int year,
+               int *hd_elems, const int fday, const int count));
+extern void
+  at_ti_hdy __P_ ((Bool * init_data,
+               const Bool detected,
+               int easter,
+               const int year,
+               int *hd_elems, const int fday, const int count));
+extern void
+  at_sa_hdy __P_ ((Bool * init_data,
+               const Bool detected,
+               int easter,
+               const int year,
+               int *hd_elems, const int fday, const int count));
+extern void
+  at_ka_hdy __P_ ((Bool * init_data,
+               const Bool detected,
+               int easter,
+               const int year,
+               int *hd_elems, const int fday, const int count));
+extern void
+  at_st_hdy __P_ ((Bool * init_data,
+               const Bool detected,
+               int easter,
+               const int year,
+               int *hd_elems, const int fday, const int count));
+extern void
+  at_oo_hdy __P_ ((Bool * init_data,
+               const Bool detected,
+               int easter,
+               const int year,
+               int *hd_elems, const int fday, const int count));
+extern void
+  at_no_hdy __P_ ((Bool * init_data,
+               const Bool detected,
+               int easter,
+               const int year,
+               int *hd_elems, const int fday, const int count));
+extern void
+  at_bu_hdy __P_ ((Bool * init_data,
+               const Bool detected,
+               int easter,
+               const int year,
+               int *hd_elems, const int fday, const int count));
+extern void
+  at_wi_hdy __P_ ((Bool * init_data,
+               const Bool detected,
+               int easter,
+               const int year,
+               int *hd_elems, const int fday, const int count));
 extern void
   au_ct_hdy __P_ ((Bool * init_data,
                   const Bool detected,
diff --git a/src/hd-defs.h b/src/hd-defs.h
index f3e737d..b952bcf 100644
--- a/src/hd-defs.h
+++ b/src/hd-defs.h
@@ -655,6 +655,10 @@
 #  define HD_W_TUBMANS_BIRTHDAY                 549
 #  define HD_YAP_DAY                            550
 #  define HD_DAY_OF_CZECH_STATEHOOD             551
+#  define HD_DAY_OF_THE_REFERENDUM              552
+#  define HD_SAINT_FLORIAN                      553
+#  define HD_RUPERT_OF_SALZBURG                 554
+#  define HD_SAINT_LEOPOLD_III                  555
 # endif        /* !HD_TOP20CC */
 
 
-- 
mfg bw1
git 2.14.4




reply via email to

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