Introduction | Usage | Editing Free-Cal.Ini | End User License Agreement

Editing Free-Cal.Ini

Someday I'll add a user interface to add and remove events from the calendar. In the meantime, you can edit Free-Cal.Ini where the events are stored. Free-Cal.Ini is a plain text file. You can edit it with NotePad. Don't edit it with Word or WordPad. The file installed on your system looks like this:

[Fixed]
0101=New Year's Day
0317=St. Patrick's Day
0704=Independence Day
1111=Veterans' Day
1225=Christmas Day
0106=Epiphany
0202=Groundhog Day
0214=Valentine's Day
0425=Secretary's Day
0501=May Day
0614=Flag Day
0815=Assumption
1006=German-American Day
1031=Halloween
1101=All Saints' Day
1208=Immaculate Conception
1224=Christmas Eve
1231=New Year's Eve

[Movable]
1,2,3=Martin Luther King Day
2,2,3=President's Day
5,2,5=Memorial Day
9,2,1=Labor Day
10,2,2=Columbus Day
11,5,4=Thanksgiving
4,1,1=Daylight Savings Time Begins
5,1,2=Mother's Day
6,1,3=Father's Day
10,1,5=Daylight Savings Time Ends
11,1,1=New York Marathon
E-47=Mardi Gras
E-46=Ash Wednesday
E-7=Palm Sunday
E-2=Good Friday
E=Easter
E+1=Easter Monday
E+39=Ascension
E+49=Pentecost
E+60=Corpus Christi
A=1st Advent
A+7=2nd Advent
A+14=3rd Advent
A+21=4th Advent
SP=First Day of Spring
SU=First Day of Summer
FA=First Day of Autumn
WI=First Day of Winter

The programmers among you will recognize this as a Windows private profile. The format is self-evident. The events listed under the [Fixed] heading are just that, fixed. Meaning that they occur on the same date every year. The format is:

mmdd=description

where: mm is the two digit month (1=January)
    dd is the month day (1-31)
    description is what appears in the popup menu

Movable events occur relative to another date. Columbus day, for instance, occurs on the second Monday of October. These are relatively straight forward to calculate.

Easter is another story and can make for an interesting research topic. There are several algorithms devised over the centuries to capture just when Easter occurs. The rule is generally the first Sunday after the first full moon after the Spring equinox. But there are exceptions. Perhaps the easiest and best know algorithm is Butcher's, devised in the 18 century by a mathematician of the same name. It is certainly the most straightforward to implement.

For the solstice and equinox calculations, you have to look to a book on astronomical calculations. The calculation is a complicated and required a some 64-bit math to get it to work without too many round-off errors (so much for my "simple" calendar program".

Moveable dates come in four flavors. The first events (like Memorial day) are relative to some day of the week (like the last Monday in May). The format is:

mm,wd,nth=description

where: mm is a one or two digit month (1-12)
    wd is the week day (1=Sunday, 2=Monday)
    nth is the week of the month it occurs (1-5 where 5 is means the last week of the month)

E is Easter. Many religious events occur as an offset from Easter. Add or subtract the desired number of days.

A is for advent. Same rules as Easter.

SP is the Spring equinox
SU is the Summer solstice
FA is the Fall equinox
WI is the Winter solstice

Don't worry to much about messing up the file. Free-Cal simply ignores any line it doesn't understand.

Introduction | Usage | Editing Free-Cal.Ini | End User License Agreement