<!---  Macros for defining sections in a text and printing a table
       of contents ---->

<set sectctr=1>
<!--- This metatag defines a section.  It assignes the block to 
      the variable sect$$sectctr and increases the sectctr.  --->
<blockdef name="section" option="title label">
  <set sectt$sectctr=$title global>
  <if label><set sectl$label=$sectctr global></if>
  <block name=sect$sectctr expand global><use block noexpand></block>
  <inc sectctr>
</blockdef>
<def name="refsect" option="label">
<a href="#sect${sectl$label}">section <use sectl$label></a></def>
<file template="section.htt">
