Format of schedtab input
The schedtab program takes as input a list of
commands specifying the dimensions and content of the output
table. These commands are as follows:
- grain_time=time - Specifies the granularity
of the output table; default is 30 minutes.
- start_time=time - Specifies the time of the
first table row. Since the rows are given only to the
granularity of grain_time, the time is rounded down to
the nearest grain. For example, if grain_time is 30
minutes and start_time is 9:10, the table will start
at 9:00.
- end_time=time - Specifies the time of the
last table row. Since the rows are given only to the
granularity of grain_time, the time is rounded up to
the nearest grain. For example, if grain_time is 30
minutes and end_time is 9:10, the table will end
at 9:30.
- options=optstring - Provides an alternative
to the command-line option set. The optstring is a
comma-delimited set of options from the following set:
- weekends, noweekends - Show Sunday and
Saturday on the table.
- merge, nomerge - Merge vertically
adjacent blank table cells.
- blanks, noblanks - Place an
in each blank cell; this is on by default.
- colors, nocolors - Show the entries
in color, as specified by their color fields. This is
on by default.
- page, nopage - Generate a full HTML
document, browser-ready. nopage generates only the table
code, with no surrounding HTML. This is off by default.
Note that there is a command-line parameter,
--options=..., which obeys the same rules as the
options script command. The command-line options
always take precedence over those given in the input file.
- start_day=dayname - Table columns begin with
the specified day; default is Sunday.
- table_html=string - HTML code to insert
verbatim inside the <table> tag in the generated output.
For example, table_html=border=1 border-color=#888888 cellpadding=5
cellspacing=0 would be a valid line. Consecutive
table_html commands concatenate in the output.
- header=string - HTML code to insert
verbatim between the <head></head> tags in the
generated output. This could be e.g. a page title or meta
keywords. Successive header commands concatenate in
the output. header is a block command.
- body_header - HTML code to insert verbatim between
the opening <body> tag and the schedule table in the
generated output. This could be e.g. a headline or some body
text. body_header is a block command.
- body_footer - HTML code to insert verbatim between
the schedule table and the closing </body> tag in the
generated output. This could be e.g. some body text or a
date-modified line. body_footer is a block command.
Block commands are commands which introduce a
sequence of parameter lines terminated by a line containing
only the keyword end. For example, since
body_header is a block command, one may write
body_header
<h1>My Schedule</h1>
Some body text.
<p> Some more body text.
end
instead of the more cumbersome, but equally valid,
body_header= <h1>My Schedule</h1>
body_header=
body_header= Some body text.
body_header= <p>Some more body text.
The table entries themselves are given as records delimited by
the commands entry and end. Within the
entry environment, the following commands are recognized:
- text=string - The content of the entry,
in HTML, possibly including (e.g.) HTML links.
- color=color - The background color of the
cell, in a format which could be included verbatim in an HTML
tag; for example, color=#CC00CC or color=red.
- start_time=time - The starting time of
this entry.
- end_time=time - The ending time of
this entry. For example, an entry with start_time=9:30
and end_time=10:30 would fill two cells, given a
granularity of 30 minutes. Changing end_time to
10:31 would make it fill three cells; changing end_time
to 10:20 would have no observable effect.
- days=days - The days on which this entry
ought to be recorded. days can be for example
MWF, or a list such as Monday,Wed,Fri. The
"string" method MWF is recommended, since it is
smart enough to treat for example MWT as the days
Monday, Wednesday, and Thursday (not Tuesday!), and it
recognizes the aliases AHRU for Saturday, Thursday,
Thursday, and Sunday, respectively.
In the case of a list of day names, each name is treated as
the first day (in Sunday-first order) with that string as a
prefix; e.g. M,W,T represents the days Monday,
Wednesday, and Tuesday, not Thursday. The letters R
and H both represent Thursday when used in
MTWRF strings, but not when used in
M,T,W,Th,F lists.
An example of a complete input file is
grain_time=30m
start_time=9:00am
end_time=5:00
options=noweekends
entry
text=15-411
color=#CCCCCC
days=TR
start_time=1:30
end_time=2:50
end
entry
text=73-100 Basic Economics
color=blue
days=M,W,Fri
start_time=noon
end_time=12:50
end