A C program for a Calendar in LaTeX.
Earl Chew
cechew at bruce.OZ
Thu Nov 30 20:49:34 AEST 1989
>From article <778 at stat.fsu.edu>, by naras at stat.fsu.edu (B. Narasimhan):
> /* This is "lxcal.c", a C program to produce a Calendar in LaTeX. No
Here's one that I meant to post ages ago. It's written entirely in TeX/LaTeX.
The following shows how to run it:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Script started on Thu Nov 30 20:45:13 1989
bruce:/tmp/cal.21> latex cal
This is TeX, Version 2.0 for Pyramid OSx (preloaded format=lplain 87.9.18)
(cal.tex
LaTeX Version 2.09 - Released 19 April 1986
(/usr/lib/tex/macros/article.sty
Document Style 'article'. Released 23 September 1985
(/usr/lib/tex/macros/art12.sty)) (/postg/cechew/tex/macros/a4.sty
A4 Page Size. July 1988
) (cal.sty
Calendar Style Version 1.1 May 1989
)
No file cal.aux.
LaTeX Calendar
Year: 1989
Month: jun
(dates.tex) (events.tex) [1] (cal.aux (dates.aux) (events.aux))
Output written on cal.dvi (1 page, 2844 bytes).
Transcript written on cal.log.
bruce:/tmp/cal.22> ^D
script done on Thu Nov 30 20:45:49 1989
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Responding with an empty line at the `Month:' prompt will generate the a
calendar for the entire year. The file dates.tex contains special dates. The
file events.tex contains special dates of a more personal nature.
Enjoy.
Earl
-------------------------------------------------------------------------------
#! /bin/sh
# This is a shell archive. Remove anything before this line, then unpack
# it by saving it into a file and typing "sh file". To overwrite existing
# files, type "sh file -c". You can also feed this as standard input via
# unshar, or by typing "sh <file", e.g.. If this archive is complete, you
# will see the following message at the end:
# "End of shell archive."
# Contents: cal.sty cal.tex dates.tex events.tex
# Wrapped by cechew at bruce on Thu Nov 30 20:41:27 1989
PATH=/bin:/usr/bin:/usr/ucb ; export PATH
if test -f 'cal.sty' -a "${1}" != "-c" ; then
echo shar: Will not clobber existing file \"'cal.sty'\"
else
echo shar: Extracting \"'cal.sty'\" \(6060 characters\)
sed "s/^X//" >'cal.sty' <<'END_OF_FILE'
X% Calendar Style
X%
X% Author: C. E. Chew
X% Date: May 1989
X%
X% This style file contains the calendar generating macros for LaTeX.
X% The following macros are defined:
X%
X% \DayOfWeek computed the day of week
X% \Calendar generate a box contained a calendar
X% \date mark a date with an event
X%
X% Patchlevel 1.0
X%
X% Edit History:
X%
X% 11 Aug 1989 Updated for release
X%
X\typeout{Calendar Style Version 1.1 May 1989}%
X% The \dow macro computes the day of the week for a given date.
X% The arguments are:
X%
X% #1 day 1..31
X% #2 month 1..12
X% #3 year
X%
X% The result in returned in \dow with 0=Sunday and 6=Saturday.
X%
X\newcount\dow% day of week
X\def\DayOfWeek#1#2#3{{%
X\def\Day{\count0 }\def\Month{\count2 }\def\Year{\count4 }\def\Century{\count6 }%
X\Day=#1 \Month=#2 \Year=#3 %
X\advance\Month by-2 %
X\ifnum\Month<1 \advance\Month by12 \advance\Year by-1 \fi%
X\Century=\Year \divide\Century by100 \multiply\Century by-100 %
X\advance\Year by\Century \divide\Century by100 %
X\dow=\Month \multiply\dow by26 \advance\dow by-2 \divide\dow by10 %
X\advance\dow by\Day \advance\dow by\Year%
X\advance\dow by\Century \advance\dow by\Century%
X\divide\Century by-4 \advance\dow by\Century%
X\divide\Year by4 \advance\dow by\Year%
X\count255=\dow \divide\count255 by7 \multiply\count255 by-7 %
X\advance\dow by\count255 %
X\ifnum\dow<0 \advance\Dow by7 \fi%
X\global\dow=\dow%
X}}%
X%
X% The \Calendar macro prints a the calendar for one month on
X% one page. The arguments are:
X%
X% #1 month 1=January 12=December
X% #2 year
X% #3 size of calendar entries --- empty if not required
X% #4 size of header
X% #5 format for tabular environment
X% #6 days of week header, this should be consister with #5
X% and should probably use \horizontal in place of \hline
X% #7 \iftrue to print horizontal lines: this causes \horizontal
X% to be defined as \hline or \empty
X% #8 height of vbox --- only used if #3 is not empty
X%
X\newcount\ld% last day in month
X\newcount\td% today --- first day of month
X\newcount\w% number of weeks in this month
X\newcount\lc% number of days in last week
X\newdimen\baseskip% saved baseline skip
X\newdimen\digitheight% how high to make the digits
X%
X\def\Calendar#1#2#3#4#5#6#7#8{{%
X%
X% Remember the size of calendar entries.
X%
X\def\entrysize{#3}%
X%
X% Determine the size of the digits.
X%
X\setbox0=\hbox{0123456789}%
X\digitheight=1\tabcolsep \advance\digitheight by\ht0 %
X%
X% Remember \baselineskip
X%
X\baseskip=1\baselineskip%
X%
X% Compute the number of days in this month. The result is left in
X% \ld.
X%
X\ifcase#1 %
X\or\def\name{January}\ld=31 %
X\or\def\name{February}\ld=28 %
X \count0=#2 \divide\count0 by4 \multiply\count0 by4 %
X \ifnum\count0=#2 \count0=#2 \divide\count0 by100 \multiply\count0 by100 %
X \ifnum\count0=#2 \count0=#2 \divide\count0 by400 \multiply\count0 by400 %
X \ifnum\count0=#2 \ld=29 %
X \fi%
X \else \ld=29 %
X \fi%
X \fi%
X\or\def\name{March}\ld=31 %
X\or\def\name{April}\ld=30 %
X\or\def\name{May}\ld=31 %
X\or\def\name{June}\ld=30 %
X\or\def\name{July}\ld=31 %
X\or\def\name{August}\ld=31 %
X\or\def\name{September}\ld=30 %
X\or\def\name{October}\ld=31 %
X\or\def\name{November}\ld=30 %
X\or\def\name{December}\ld=31 \fi%
X\expandafter\lowercase\expandafter{%
X \expandafter\def\expandafter\lname\expandafter{\name}}%
X%\showthe\ld%
X%
X% Compute the day of the week on which the 1st of this month
X% begins. The answer is left in \td with 0=Sunday and 6=Saturday.
X%
X\DayOfWeek{1}{#1}{#2}\td=\dow%
X%
X% Compute the last day in the month. Leave the answer in \lc with
X% 1=Sunday 7=Saturday. This enumeration differs from \td since
X% \lc is used later for \cline.
X%
X\lc=\ld \advance\lc by\td \divide\lc by7 \multiply\lc by-7 %
X\advance\lc by\ld \advance\lc by\td%
X%
X% Compute the number of weeks in the month. This is used to set
X% up the \weekx macros. It is not possible to do this on the fly
X% within the tabular environment since it introduces empty columns.
X%
X\w=\ld \advance\w by\td \advance\w by6 \divide\w by7 %
X\ifnum\w>0 \def\weeki{\oneweek}\else\def\weeki{}\fi \advance\w by-1 %
X\ifnum\w>0 \def\weekii{\oneweek}\else\def\weekii{}\fi \advance\w by-1 %
X\ifnum\w>0 \def\weekiii{\oneweek}\else\def\weekiii{}\fi \advance\w by-1 %
X\ifnum\w>0 \def\weekiv{\oneweek}\else\def\weekiv{}\fi \advance\w by-1 %
X\ifnum\w>0 \def\weekv{\oneweek}\else\def\weekv{}\fi \advance\w by-1 %
X%
X% Compute the weekday of the Sunday before the 1st of the month. The
X% result not taken mod 7 and will not be positive.
X%
X\multiply\td by-1 \advance\td by1 %
X%
X% Process today's date looking for any significant events.
X%
X\def\dotoday{\ifx\entrysize\empty \the\td%
X \else \vbox to#8{\vrule height\digitheight width0pt depth0pt%
X \the\td%
X \vfill%
X #3\raggedright%
X \csname\lname\romannumeral\the\td\endcsname%
X \vbox{}%
X }\fi}%
X%
X% This macro will process one day of the calendar. It will then
X% advance the day counter.
X%
X\def\oneday{%
X\ifnum\td>0 %
X \ifnum\td>\ld \multicolumn{1}{}{}\else \dotoday \fi%
X\else%
X \global\advance\td by35 %
X \ifnum\td>\ld \else \dotoday \fi%
X \global\advance\td by-35 %
X\fi%
X\global\advance\td by1 %
X}%
X%
X% This macro will process one week of the calendar. This assumes that
X% there will be at least one non-empty day in the week. If this is
X% the last week, only the week up until the last day is printed.
X%
X\def\oneweek{%
X\oneday & \oneday & \oneday & \oneday & \oneday & \oneday & \oneday \\
X#7\ifnum\td>\ld\cline{1-\the\lc}\else\hline\fi\fi%
X}%
X%
X% Set the macro to print horizontal lines
X%
X#7\def\horizontal{\hline}\else\let\horizontal=\empty \fi
X%
X% Print the calendar for this month
X%
X\begin{tabular}{#5}
X\multicolumn{7}{c}{#4 \name\ #2} \\[1\baseskip] \horizontal
X#6
X\weeki \weekii \weekiii \weekiv \weekv
X\end{tabular}}}
X%
X% The \date macro allows the user to declare events on particular
X% days. The arguments are:
X%
X% #1 the month (eg January) --- not case sensitive
X% #2 the day
X% #3 text for the event
X%
X\def\date#1#2#3{{\lowercase{\def\ldate{#1}}%
X \expandafter\gdef\csname\ldate\romannumeral #2 \endcsname{#3}}}%
END_OF_FILE
if test 6060 -ne `wc -c <'cal.sty'`; then
echo shar: \"'cal.sty'\" unpacked with wrong size!
fi
# end of 'cal.sty'
fi
if test -f 'cal.tex' -a "${1}" != "-c" ; then
echo shar: Will not clobber existing file \"'cal.tex'\"
else
echo shar: Extracting \"'cal.tex'\" \(3394 characters\)
sed "s/^X//" >'cal.tex' <<'END_OF_FILE'
X%
X% LaTeX Calendar Driver
X%
X% Author: C. E. Chew
X% Date: May 1989
X%
X% This is the main program for printing out calendars. It provides
X% a user interface for the calendar style. The style file contains
X% the code that actually produces the calendars.
X%
X% The program will prompt for the year and the month. The year should
X% be entered in full (eg 1989). The month should be entered using
X% the first three letters of the month in question, case not being
X% significant (eg aug). Responding with an empty line for the month
X% causes a calendar for the entire year to be printed out.
X%
X% The program will include the file dates.tex which contains significant
X% dates for the year. The user is free to create the file events.tex
X% which has the same format as dates.tex. events.tex should contain
X% events of a significant and personal nature (eg birthdays).
X%
X% Patchlevel 1.0
X%
X% Edit History:
X%
X% 11 Aug 1989 Updated for release
X%
X\documentstyle[a4,12pt,cal]{article}%
X\pagestyle{empty}%
X%
X\oddsidemargin -1in%
X\evensidemargin -1in%
X\textwidth 8in%
X%
X\begin{document}%
X%
X\typeout{LaTeX Calendar}%
X%
X\def\Jan{jan}\def\Feb{feb}\def\Mar{mar}\def\Apr{apr}%
X\def\May{may}\def\Jun{jun}\def\Jul{jul}\def\Aug{aug}%
X\def\Sep{sep}\def\Oct{oct}\def\Nov{nov}\def\Dec{dec}%
X%
X\def\lread{{\endlinechar=-1 \global\read-1 to\line}}%
X%
X\def\advmonth#1{\advance\month by#1 %
X \ifnum\month<1 \month=12 \advance\year by-1 \fi%
X \ifnum\month>12 \month=1 \advance\year by1 \fi}%
X%
X\def\littlemonth{{\tabcolsep=0.75mm%
X \Calendar{\the\month}{\the\year}{}{}{rrrrrrr}{%
X Su & Mo & Tu & We & Th & Fr & Sa \\}{\iffalse}{}}}%
X%
X\def\bigmonth{\Calendar{\the\month}{\the\year}{\scriptsize}{\Huge}%
X {|p{2cm}|p{2cm}|p{2cm}|p{2cm}|p{2cm}|p{2cm}|p{2cm}|}%
X {\multicolumn{1}{|c|}{Sun}&%
X \multicolumn{1}{c|}{Mon}&%
X \multicolumn{1}{c|}{Tue}&%
X \multicolumn{1}{c|}{Wed}&%
X \multicolumn{1}{c|}{Thu}&%
X \multicolumn{1}{c|}{Fri}&%
X \multicolumn{1}{c|}{Sat}\\ \horizontal}{\iftrue}{3cm}}%
X%
X\def\onepage{\setbox0=\hbox{\bigmonth}%
X \centerline{\hbox to\wd0{%
X \fbox{\footnotesize\advmonth{-1}\littlemonth}\hfil%
X \fbox{\footnotesize\advmonth{1}\littlemonth}}}%
X \vspace{1cm}%
X \centerline{\box0}}%
X%
X% Read the year. If the line is empty, the current year is taken
X% to be the default.
X%
X\message{Year: }\lread \ifx\line\empty \else \newcount\year \year=\line \fi%
X%
X% Read the month. If the line is empty, the calendar for the entire
X% year is printed.
X%
X\newcount\month \loop%
X \message{Month: }\lread%
X \ifx\line\empty%
X \month=-1 %
X \else%
X \month=0 %
X \lowercase\expandafter{%
X \expandafter\def\expandafter\line\expandafter{\line}}%
X \ifx\line\Jan\month=1 \fi \ifx\line\Feb\month=2 \fi%
X \ifx\line\Mar\month=3 \fi \ifx\line\Apr\month=4 \fi%
X \ifx\line\May\month=5 \fi \ifx\line\Jun\month=6 \fi%
X \ifx\line\Jul\month=7 \fi \ifx\line\Aug\month=8 \fi%
X \ifx\line\Sep\month=9 \fi \ifx\line\Oct\month=10 \fi%
X \ifx\line\Nov\month=11 \fi \ifx\line\Dec\month=12 \fi%
X \fi%
X\ifnum\month=0 \repeat%
X%
X\include{dates}%
X\include{events}%
X%
X\ifnum\month=-1 \month=1 \loop \onepage \advance\month by1 %
X \ifnum\month<13 \repeat%
X\else \onepage%
X\fi%
X%
X\end{document}
END_OF_FILE
if test 3394 -ne `wc -c <'cal.tex'`; then
echo shar: \"'cal.tex'\" unpacked with wrong size!
fi
# end of 'cal.tex'
fi
if test -f 'dates.tex' -a "${1}" != "-c" ; then
echo shar: Will not clobber existing file \"'dates.tex'\"
else
echo shar: Extracting \"'dates.tex'\" \(5556 characters\)
sed "s/^X//" >'dates.tex' <<'END_OF_FILE'
X%
X% Special Dates File
X%
X% This file should contain special dates. The format is:
X%
X% \date{month}{day}{text}
X%
X% The name of the month should be typed in full. Case is not significant.
X% It is also possible to do complicated things like computing the days
X% for Easter --- but only if you're a TeXpert.
X%
X% Put a file containing text like this in your current directory when you
X% LaTeX cal.tex. The file will be read in after the year and month are
X% read. The year is available in \year and the number of the month is
X% available in \month. If \month is -1 then the entire year is about
X% to be printed.
X%
X% Patchlevel 1.0
X%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% JANUARY %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X\date{January}{1}{New Year's Day}%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% FEBRUARY %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% MARCH %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% APRIL %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% MAY %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% JUNE %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% JULY %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% AUGUST %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% SEPTEMBER %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% OCTOBER %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% NOVEMBER %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% DECEMBER %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X\date{December}{25}{Christmas Day}%
X\date{December}{26}{Boxing Day}%
X\date{December}{31}{New Year's Eve}%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% EASTER %
X% %
X% This algorithm is taken from: %
X% %
X% The Calculation of Easter %
X% D. E. Knuth %
X% CACM April 1962 p 209 %
X% %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X{%
X\def\Golden{\count0 }% year in Mentonic cycle
X\def\Easter{\count0 }% Easter Sunday
X\def\GrCor{\count2 }% Gregorian correction
X\def\ClCor{\count4 }% Clavian correction
X\def\Epact{\count6 }% age of calendar moon at start of year
X\def\Century{\count6 }% century
X\def\Extra{\count8 }% when Sunday occurs in March
X\Golden=\year \divide\Golden by19 \multiply\Golden by-19 %
X\advance\Golden by\year \advance\Golden by1 %
X\ifnum\year>1582 %
X \Century=\year \divide\Century by100 \advance\Century by1 %
X \GrCor=\Century \multiply\GrCor by3 \divide\GrCor by-4 \advance\GrCor by12 %
X \ClCor=\Century \advance\ClCor by-18 \divide\ClCor by-25 %
X \advance\ClCor by\Century \advance\ClCor by-16 \divide\ClCor by3 %
X \Extra=\year \multiply\Extra by5 \divide\Extra by4 %
X \advance\Extra by\GrCor \advance\Extra by-10 %
X \Epact=\Golden \multiply\Epact by11 \advance\Epact by20 %
X \advance\Epact by\ClCor \advance\Epact by\GrCor %
X \count255=\Epact \divide\count255 by30 \multiply\count255 by-30 %
X \advance\Epact by\count255 %
X \ifnum\Epact>0 \else \advance\Epact by30 \fi%
X \ifnum\Epact=25 %
X \ifnum\Golden>11 %
X \advance\Epact by1 %
X \fi%
X \else%
X \ifnum\Epact=24 %
X \advance\Epact by1 %
X \fi%
X \fi%
X\else%
X \Extra=\year \multiply\Extra by5 \divide\Extra by4 %
X \Epact=\Golden \multiply\Epact by11 \advance\Epact by-4 %
X \count255=\Epact \divide\count255 by30 \multiply\count255 by-30 %
X \advance\Epact by\count255 \advance\Epact by1 %
X\fi%
X\Easter=\Epact \multiply\Easter by-1 \advance\Easter by44 %
X\ifnum\Easter<21 %
X \advance\Easter by30 %
X\fi%
X\advance\Extra by\Easter \count255=\Extra %
X\divide\count255 by7 \multiply\count255 by-7 \advance\Extra by\count255 %
X\multiply\Extra by-1 \advance\Easter by\Extra \advance\Easter by7 %
X\ifnum\Easter>31 %
X \advance\Easter by-31 %
X \date{April}{\the\Easter}{Easter}%
X \advance\Easter by1 %
X \date{April}{\the\Easter}{Easter Monday}%
X \advance\Easter by1 %
X \date{April}{\the\Easter}{Easter Tuesday}%
X \advance\Easter by-3 %
X \date{April}{\the\Easter}{Easter Saturday}%
X \advance\Easter by-1 %
X \date{April}{\the\Easter}{Easter Friday}%
X\else%
X \date{March}{\the\Easter}{Easter}%
X \advance\Easter by1 %
X \date{March}{\the\Easter}{Easter Monday}%
X \advance\Easter by1 %
X \date{March}{\the\Easter}{Easter Tuesday}%
X \advance\Easter by-3 %
X \date{March}{\the\Easter}{Easter Saturday}%
X \advance\Easter by-1 %
X \date{March}{\the\Easter}{Easter Friday}%
X\fi%
X}%
END_OF_FILE
if test 5556 -ne `wc -c <'dates.tex'`; then
echo shar: \"'dates.tex'\" unpacked with wrong size!
fi
# end of 'dates.tex'
fi
if test -f 'events.tex' -a "${1}" != "-c" ; then
echo shar: Will not clobber existing file \"'events.tex'\"
else
echo shar: Extracting \"'events.tex'\" \(875 characters\)
sed "s/^X//" >'events.tex' <<'END_OF_FILE'
X%
X% Special Dates File
X%
X% This file should contain special dates. The format is:
X%
X% \date{month}{day}{text}
X%
X% The name of the month should be typed in full. Case is not significant.
X% It is also possible to do complicated things like computing the days
X% for Easter --- but only if you're a TeXpert.
X%
X% Put a file containing text like this in your current directory when you
X% LaTeX cal.tex. The file will be read in after the year and month are
X% read. The year is available in \year and the number of the month is
X% available in \month. If \month is -1 then the entire year is about
X% to be printed.
X%
X% Patchlevel 1.0
X%
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X% BIRTHDAYS %
X%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
X\date{June}{8}{Stuart's Birthday}%
X\date{December}{28}{Arthur's Birthday}%
END_OF_FILE
if test 875 -ne `wc -c <'events.tex'`; then
echo shar: \"'events.tex'\" unpacked with wrong size!
fi
# end of 'events.tex'
fi
echo shar: End of shell archive.
exit 0
-------------------------------------------------------------------------------
--
Earl Chew, Dept of Computer Science, Monash University, Australia 3168
ARPA: cechew%bruce.cs.monash.oz.au at uunet.uu.net ACS : cechew at bruce.oz
----------------------------------------------------------------------
More information about the Comp.lang.c
mailing list