3.8 Index

  3.8.1 LaTeX
  3.8.2 Scr
  3.8.3 multiind
  3.8.4 Index
  3.8.5 texinfo
  3.8.6 ConTeXt
  3.8.7 Tables
  3.8.8 letters
  3.8.9 mwcls
  3.8.10 Into Columns

3.8.1 LaTeX

<..config book-report-article..>
 <.book-report-article index.>
-_-_-

3.8.2 Scr

<..32,4 report,book..>+
 \Configure{@begin}{theindex}{\ifx \indexname\empty \else
     \chapter*{\indexname}\fi}
-_-_-

<..configure html4 article..>
 \Configure{@begin}{theindex}{\ifx \indexname\empty \else
     \section*{\indexname}\fi}
-_-_-

<..scr report,book..>+
 \Configure{@begin}{theindex}{\ifx \indexname\empty \else
     \chapter*{\indexname}\fi}
-_-_-

3.8.3 multiind

<..configure html4 multind..>
 \Configure{@begin}{theindex}
    {\ifx \indexname\empty \else<.toc for multind.>\fi}
-_-_-

3.8.4 Index

<..configure html4 index..>
 \Configure{NoSection}
   {\let\sv:index=\p@index \let\sv:label=\label
    \let\sv:newline=\newline \def\newline{ }%
    \def\p@index[##1]{\@gobble}\let\label=\@gobble
    <.nolink ref.>%
   }
   {\let\p@index=\sv:index \let\label=\sv:label
    <.restore ref.>%
    \let\newline=\sv:newline
   }
-_-_-

3.8.5 texinfo

<..configure html4 texinfo..>
 \Configure{index}
   {\IgnorePar\leavevmode\EndP\Tg<div class="index">}
   {\IgnorePar\EndP\Tg</div>}
   {\leavevmode\Tg<span class="entry">}
   {\Tg</span>\expandafter\Tg<br />\IgnorePar}
-_-_-

3.8.6 ConTeXt

<..configure html4 context..>
 \catcode‘\!=11
 <.context core-int.>
 <.context core-lst.>
 <.context etc.>
 <.context sectioning.>
 <.context system.>
 <.context toc.>
 <.context description.>
 <.context item group.>
 <.context core-ver.>
 <.context spacing.>
 <.context floats.>
 <.context tabs.>
 <.context tables.>
 <.context core-ntb.>
 <.context index.>
 <.context core-spa.>
 <.context core-ref.>
 <.context core-rul.>
 <.context core-not.>
 <.context core-mat.>
 <.context cont-log.>
 <.context supp-mps.>
 \catcode‘\!=12
-_-_-

<..context core-mat..>
 \Configure{-@@fm}
    {\ifvmode
       \IgnorePar\EndP\HCode{<div class="formula-no">}%
       \def\end:margp{\ifvmode \IgnorePar\fi \EndP \HCode{</div>}}%
       \par
     \else
       \SaveEndP
       \HCode{<span class="formula-no">}%
       \bgroup
          \Configure{HtmlPar}{\HCode{<br />}}{\HCode{<br />}}{}{}%
       \def\end:margp{\egroup\HCode{</span>}\RecallEndP}%
     \fi
    }
    {\end:margp}
 \Css{.formula-no {width:5\%; float:right; text-align:right;
   margin-right:auto; }}
-_-_-

<..context core-mat..>+
 \Configure{mtable}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<table class="mtable">}}
    {\HCode{</table>}}
    {\HCode{<tr>}}
    {\HCode{</tr>}}
    {\HCode{<td>}}
    {\HCode{</td>}}
 \Configure{mathalignment}
    {\ifvmode \IgnorePar\fi \EndP
     \Css{table.\currentmathalignment { margin-left:5\%; }}%
     \Css{td.\currentmathalignment { text-align:left; }}%
     \HCode{<table class="\currentmathalignment">}}
    {\HCode{</table>}}
    {\HCode{<tr class="\currentmathalignment">}}
    {\HCode{</tr>}}
    {\HCode{<td class="\currentmathalignment">}}
    {\HCode{</td>}}
 \NewConfigure{align}{6}
 \Configure{align}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<table class="align">}}
    {\HCode{</table>}}
    {\HCode{<tr class="align">}}
    {\HCode{</tr>}}
    {\HCode{<td class="align">}}
    {\HCode{</td>}}
 \Css{table.align { margin-left:5\%; }}
 \Css{td.align { text-align:left; }}
-_-_-

<..context core-mat..>+
 \Configure{intertext}
    {\f:mtable\d:mtable\c:mtable\HCode{<td colspan="10"
                           class="intertext">}}
    {\f:mtable\d:mtable\c:mtable\e:mtable}
 \Css{.intertext {text-align:left;}}
-_-_-

<..context core-mat..>+
 \Configure{frac}
    {\Picture+{ class="frac"}\bgroup}
    {}{}
    {\egroup\EndPicture}
 \Css{.frac {vertical-align:middle;}}
-_-_-

<..context supp-mps..>
 \Configure{MPcode}
     {\Picture*[pic]{}}
     {\EndPicture}
-_-_-

<..context cont-log..>
 \def\:temp{LaTeX}
 \HLet\LaTeX\:temp
-_-_-

<..context core-int..>
 {
   \def\:tempc{%
     \catcode‘\.=12
     \gdef\:tempc}
   \:tempc#1.#2.{#1}
 }
 {\Configure{Needs}{Font\string_Size: #1}%
    \Needs{\expandafter\:tempc\the\bodyfontsize .}}
-_-_-

<..context core-spa..>
 \Configure{crlf}{\HCode{<br />}}
-_-_-

<..context core-ref..>
 \Configure{externaldocument}{\Link}{\EndLink}
 \Configure{-@@ur}
    {\HCode{<span class="url">}}
    {\HCode{</span>}}
-_-_-

<..context core-rul..>
 \Configure{framed}
    {\ifvmode
        \def\end:framed{\ifvmode \IgnorePar\fi\EndP\HCode{</div>}}%
        \IgnorePar \EndP
       \HCode{<div <.framed deco.>>}%
     \else
       \def\end:framed{\HCode{</span>}}%
       \HCode{<span <.framed deco.>>}%
     \fi
    }
    {\end:framed}
 \Css{.framed-border{border: solid black 1px; }}
 \Css{.framed-background{background-color: \#CCCCCC; }}
-_-_-

<..framed deco..>
 class="framed-\ifdim\ruledlinewidth>0em
           border%
        \else
           background%
        \fi
 "
-_-_-

<..context etc..>
 \NewConfigure{-@@ly}{2}
-_-_-

<..context chapter name..>
 \v!chapter
-_-_-

<..context section name..>
 \v!section
-_-_-

<..context subsection name..>
 \v!subsection
-_-_-

<..context subsubsection name..>
 \v!subsubsection
-_-_-

<..context subsubsubsection name..>
 \v!subsubsubsection
-_-_-

<..context subsubsubsubsection name..>
 \v!subsubsubsubsection
-_-_-

<..context chapter name pre 2006..>
 \v!hoofdstuk
-_-_-

<..context section name pre 2006..>
 \v!paragraaf
-_-_-

<..context subsection name pre 2006..>
 \v!sub \v!paragraaf
-_-_-

<..context subsubsection name pre 2006..>
 \v!sub \v!sub \v!paragraaf
-_-_-

<..context subsubsubsection name pre 2006..>
 \v!sub \v!sub \v!sub \v!paragraaf
-_-_-

<..context subsubsubsubsection name pre 2006..>
 \v!sub \v!sub \v!sub \v!sub \v!paragraaf
-_-_-

<..context sectioning..>
 \Configure{sectie}
    {\gHAdvance \sec:Level by 1\relax
     \ifnum \sec:Level=1
         \ifvmode \IgnorePar\fi \EndP
         \HCode{<div class="\cur:Name">}%
     \else
         \ifvmode \IgnorePar\fi
         \HCode{<span class="\cur:Name">}%
     \fi
    }
    {\ifnum \sec:Level=1
         \ifvmode \IgnorePar\fi \EndP
         \HCode{</div>}%
     \else
         \ifvmode \IgnorePar\fi
         \HCode{</span>}%
     \fi
     \gHAdvance \sec:Level by -1\relax
    }
 \HAssign\sec:Level=0
-_-_-

<..context sectioning..>+
 \def\:tmp#1#2{%
   \ConfigureMark{#1}
      {\HCode{<span class="titlemark">}\finalsectionnumber
       \HCode{</span>}}
   \Configure{#1}%
      {}{}
      {\ifvmode \IgnorePar\fi \EndP\IgnorePar
       \HCode{<#2 class="#1Head"\a:LRdir>}\NoFonts
       \TitleMark\space\HtmlParOff
       \bgroup
          \let\setstrut=\empty
          \let\begstrut=\empty
          \let\endstrut=\empty
      }
      {\egroup
       \EndNoFonts \HCode{</#2>}\HtmlParOn
       \IgnoreIndent \par \ShowPar}
   \Configure{#1TITLE+}{\finalsectionnumber\space##1}
   \ifx \end:secs\empty \else
     \edef\:temp{\noexpand\Configure{end#1}{\end:secs}}\:temp
   \fi
   \edef\end:secs{\end:secs,#1}%
   \NewConfigure{#1-ko}{2}
 }
 \def\end:secs{}
 \def\:tempd#1{\edef\:temp{\noexpand\:tmp{#1}}\:temp}
 
   \:tempd{<.context chapter name.>}{h1}
   \:tempd{<.context section name.>}{h2}
   \:tempd{<.context subsection name.>}{h3}
   \:tempd{<.context subsubsection name.>}{h4}
   \:tempd{<.context subsubsubsection name.>}{h5}
   \:tempd{<.context subsubsubsubsection name.>}{h5}
-_-_-

<..context toc..>
 \Configure{placecontent}
    {\ifvmode \IgnorePar\fi \EndP
     \def\toc:br{\def\toc:br{\HCode{<br />}}}%
     \HCode{<div class="tableofcontents"\a:LRdir>}\IgnorePar}
    {}
    {\IgnorePar\EndP\HCode{</div>}\ShowPar}
    {} {}
 \Configure{contenthead}
     {\ifvmode \IgnorePar\fi \EndP \HCode{<h2>}\NoFonts}
     {\ifvmode \IgnorePar\fi \EndNoFonts \HCode{</h2>}\par}
-_-_-

<..context toc..>+
 \ConfigureToc{part}
   {\toc:br
    \HCode{<span class="partToc" \a:LRdir><span class="toc-mark">}}
   {\HCode{</span>}~}
   {}
   {\HCode{</span>}}
-_-_-

<..context toc..>+
 \ConfigureToc{chapter}
   {\toc:br
    \HCode{<span class="chapterToc" \a:LRdir><span class="toc-mark">}}
   {\HCode{</span>}~}
   {}
   {\HCode{</span>}}
-_-_-

<..context toc..>+
 \ConfigureToc{section}
   {\toc:br
    \HCode{<span class="sectionToc" \a:LRdir><span class="toc-mark">}}
   {\HCode{</span>}~}
   {}
   {\HCode{</span>}}
-_-_-

<..context toc..>+
 \ConfigureToc{subsection}
   {\toc:br
    \HCode{<span class="subsectionToc" \a:LRdir><span class="toc-mark">}}
   {\HCode{</span>}~}
   {}
   {\HCode{</span>}}
-_-_-

<..context toc..>+
 \ConfigureToc{subsubsection}
   {\toc:br
    \HCode{<span class="subsubsectionToc" \a:LRdir><span class="toc-mark">}}
   {\HCode{</span>}~}
   {}
   {\HCode{</span>}}
-_-_-

<..context toc..>+
 \ConfigureToc{subsubsubsection}
   {\toc:br
    \HCode{<span class="subsubsubsectionToc" \a:LRdir><span class="toc-mark">}}
   {\HCode{</span>}~}
   {}
   {\HCode{</span>}}
-_-_-

<..context toc..>+
 \ConfigureToc{subsubsubsubsection}
   {\toc:br
    \HCode{<span class="subsubsubsubsectionToc" \a:LRdir><span class="toc-mark">}}
   {\HCode{</span>}~}
   {}
   {\HCode{</span>}}
-_-_-

<..context spacing..>
 \Configure{narrower}
    {\ifvmode \IgnorePar\fi \EndP \HCode{<div class="narrower">}}
    {\ifvmode \IgnorePar\fi \EndP \HCode{</div>}}
 \Css{div.narrower {margin-left:2em; margin-right:2em;}}
-_-_-

<..context spacing..>+
 \Configure{midaligned}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="midaligned">}}
    {\ifvmode \IgnorePar\fi \EndP  \HCode{</div>}\par}
 \Configure{leftaligned}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="leftaligned">}}
    {\ifvmode \IgnorePar\fi \EndP  \HCode{</div>}\par}
 \Configure{rightaligned}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="rightaligned">}}
    {\ifvmode \IgnorePar\fi \EndP  \HCode{</div>}\par}
 \Css{div.midaligned {text-align:center;}}
 \Css{div.leftaligned {text-align:left;}}
 \Css{div.rightaligned {text-align:right;}}
-_-_-

<..context system..>
 \Configure{startstop}
    {\ifvmode \IgnorePar \EndP
        \HCode{<div class="startstop">}\par
        \def\end:startstop{\ifvmode \IgnorePar \EndP \fi
                           \HCode{</div>}\par}%
     \else
        \HCode{<span class="startstop">}%
        \def\end:startstop{\ifvmode \IgnorePar \HCode{</span>}\par
                           \else \HCode{</span>}\fi}%
     \fi}
    {\end:startstop}
-_-_-

<..context description..>
 \Configure{description-item}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<dl class="description-item">
            <dt class="description-dt">}\everypar{}}
    {\HCode{</dt><dd class="description-dd">}\everypar{\HtmlPar}\par}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{</dd></dl>}}
-_-_-

<..context description..>+
 \Configure{description-word}
    {\HCode{<span class="description-word">}}
    {\ifvmode \IgnorePar \HCode{</span>}\par
                           \else \HCode{</span>}\fi}
-_-_-

<..context core-lst..>
 \Configure{dolist}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="dolist">}}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{</div>}}
-_-_-

<..context item group..>
 \Configure{itemgroup}
    {\ifvmode\IgnorePar\fi \EndP
     \HCode{<dl class="\currentitemgroup">}\let\end:dd=\empty}
    {\ifvmode\IgnorePar\fi \EndP \end:dd \HCode{</dl>}}
 \Configure{head-listitem}
    {\ifvmode\IgnorePar\fi \EndP
     \end:dd \HCode{<dt class="\currentitemgroup
                               -head">}}
    {\ifvmode\IgnorePar\fi \EndP
     \HCode{</dt><dd class="\currentitemgroup -head%
                                ">}\def\end:dd{\HCode{</dd>}}}
 \Configure{symbol-listitem}
    {\ifvmode\IgnorePar\fi \EndP
     \end:dd \HCode{<dt class="\currentitemgroup
                               -symbol">}}
    {\ifvmode\IgnorePar\fi \EndP
     \HCode{</dt><dd class="\currentitemgroup -symbol%
                                ">}\def\end:dd{\HCode{</dd>}}}
 \Configure{other-listitem}
    {\ifvmode\IgnorePar\fi \EndP
     \end:dd \HCode{<dt class="\currentitemgroup
                               -other">}}
    {\ifvmode\IgnorePar\fi \EndP
     \HCode{</dt><dd class="\currentitemgroup -other%
                                ">}\def\end:dd{\HCode{</dd>}}}
-_-_-

<..context item group..>+
 \Configure{itemize-group}
     {\ifvmode \IgnorePar\fi \EndP
      \HCode{<dl class="dd-\itemlevel">}\global\let\end:dd=\empty}
     {\ifvmode \IgnorePar\fi \EndP \HCode{</dd></dl>}}
 \Configure{itemize-other-item}
     {\ifvmode \IgnorePar\fi \EndP
      \HCode{\ifx\end:dd\empty\else </dd>\fi<dt>}\global\let\end:dd=\relax}
     {\ifvmode \IgnorePar\fi \EndP \HCode{</dt><dd>}\par}
 \Css{dd p{margin-top:-1.2em; margin-bottom:1.7em;}}
-_-_-

<..context core-not..>
 \HAssign\fn:c=0
 \Configure{footnote}
     {\HPage{}}
     {\EndHPage{}}
     {\HCode{<sup>}\Link{}{fnc-\fn:c}}
     {\EndLink\HCode{</sup>}}
 \Configure{footnotemark}
     {\HCode{<sup>}\gHAdvance\fn:c by 1 \Link{fnc-\fn:c}{}}
     {\ifvmode\IgnorePar\fi \EndLink\HCode{</sup>}}
-_-_-

<..context core-ver..>
 \Configure{typing}
    {\ifvmode \IgnorePar\fi \EndP \par \ShowPar
     \def\verb:par{%
       \HCode{<.show input line no.><div class="typing">}%
       \gdef\verb:par{\HCode{<br />}}}%
    }
    {\ifvmode \IgnorePar\fi \HCode{</div>}\par}
    {\verb:par}
    {\HCode{\string&}\HChar{-35}\HCode{x00A0;}}
 \Css{div.typing
        {font-family: monospace; white-space: nowrap; }}
-_-_-

<..context floats..>
 \Configure{plaatsblok}
    {\ifvmode \IgnorePar\fi \EndP\HCode{<div class="float">}}
    {\ifvmode \IgnorePar\fi \EndP\HCode{</div>}}
 \Configure{caption}
    {\HCode{<span class="caption-label">}}   {\HCode{</span>}}
    {\HCode{<span class="caption-text">}}   {\HCode{</span>}}
-_-_-

Q. Where placefigure is declared?

<..context floats..>+
 \NewConfigure{figure}{2}
 \Configure{figure}
    {\ifvmode \IgnorePar\fi \EndP\HCode{<div class="figure">}}
    {\ifvmode \IgnorePar\fi \EndP\HCode{</div>}}
 \Css{div.figure {border-top:solid black 1px; border-bottom:solid black 1px;}}
-_-_-

<..context floats..>+
 \Configure{externalfigure}{\Picture[fig]}
 \Configure{placefloat}
    {\ifvmode\IgnorePar\fi \EndP
     \HCode{<div class="place-float">}\IgnorePar }
    {\ifvmode\IgnorePar\fi \EndP\HCode{</div>}}
 \Css{.place-float  .framed-border{ border:0px;}}
 \Css{.place-float  .framed-border .framed-border{ border:1px solid black;}}
 \Css{.place-float { border-top:1px black solid;
                     border-bottom:1px black solid;
                     margin: 1em;
                     padding-top: 5px;
                     padding-bottom: 5px;
                    }}
-_-_-

<..context floats..>+
 \Configure{figure-li}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="entry"><span class="num">}\par\IgnorePar}
    {\HCode{</span><span class="title">}}
    {\HCode{</span><span class="page"><!--}}
    {\HCode{--></span></div>}}
-_-_-

<..context toc NO..>
 \Configure{title-ko}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="toc-title">}%
     \def\end:ko{\ifvmode \IgnorePar\fi \EndP \HCode{</div>}}\bgroup
       \aftergroup\end:ko
       \Configure{title-ko}{\bgroup}{\egroup}%
    }
    {\egroup }
-_-_-

3.8.7 Tables

<..context tabs..>
 \Configure{\v!tabulate}
    {\ifvmode \IgnorePar\fi
     \EndP \HCode{<table class="\v!tabulate">}}
    {\ifvmode\IgnorePar\fi\HCode{</table>}\par}
    {\HCode{<tr>}}
    {\ifvmode \IgnorePar\fi \HCode{</tr>}}
    {\HCode{<td }\ifx \csname \HAlign :T:D\endcsname\relax \else
                     \csname \HAlign :T:D\endcsname \fi\HCode{>}}
    {\HCode{</td>}}
 \Css{table.tabulate td {padding-left:0.4em; padding-right:0.4em;}}
-_-_-

<..context core-ntb..>
 \Configure{bTABLE}
   {\ifvmode \IgnorePar \fi \EndP
    \PushStack\Table:Stck\TableNo
    \gHAdvance\Next:TableNo by 1
    \global\let\TableNo=\Next:TableNo
    \HCode{<!--table \TableNo--><table class="bTABLE">}}
   {\ifvmode \IgnorePar \fi
    \HCode{</table>}\PopStack\Table:Stck\TableNo }
   {\ifvmode \IgnorePar \fi \HCode{<!--row \rowTBL--><tr>}}
   {\ifvmode \IgnorePar \fi \HCode{</tr>}}
   {\expandafter\ifx \csname bTBL\rowTBL,\colTBL\endcsname\relax
      \let\need:endTD\relax
      \ifvmode \IgnorePar \fi \HCode{<!--}%
    \else
      \let\need:endTD\def
      \HCode{<!--cell \rowTBL,\colTBL--><td id="TBL-\TableNo-\rowTBL-\colTBL"
            \expandafter\expandafter\expandafter\bTBL:sty
                                      \csname bTBL\rowTBL,\colTBL\endcsname
        >}%
    \Configure{framed}
       {\Css{td\#TBL-\TableNo-\rowTBL-\colTBL{
                 padding-left:5pt; padding-right:5pt; border:solid black 1px;
       }}}%
       {}%
    \fi
   }
   {\ifvmode \IgnorePar \fi \EndP
    \ifx \need:endTD\def
      \HCode{</td>}
    \else
      \HCode{-->}
    \fi
   }
 \def\bTBL:sty#1#2{%
    \ifnum #1>1 \space rowspan="#1"\fi
    \ifnum #2>1 \space colspan="#2" style="text-align:center;"\fi
 }
 \Css{table.bTABLE p{margin-top:0em; margin-bottom:0em;}}
 \Css{table.bTABLE{margin-left:10\%; margin-right:10\%;
           margin-top:1em; margin-bottom:1em;
       }}
 \Css{table.bTABLE {border-spacing:0px;
            border-top: solid black 1px;
            border-bottom: solid black 1px; }}
 
-_-_-

 
 \Configure{bTABLE}
   {\ifvmode \IgnorePar \fi \EndP
    \PushStack\Table:Stck\TableNo
    \gHAdvance\Next:TableNo by 1
    \global\let\TableNo=\Next:TableNo
    \HCode{<!--table \TableNo--><table class="bTABLE">}}
   {\ifvmode \IgnorePar \fi
    \HCode{</table>}\PopStack\Table:Stck\TableNo }
   {\ifvmode \IgnorePar \fi \HCode{<!--row \rowTBL--><tr>}}
   {\ifvmode \IgnorePar \fi \HCode{</tr>}}
   {\ifTag{cell-\TableNo-\rowTBL-\colTBL}%
          {\tmp:cnt=\LikeRef{cell-\TableNo-\rowTBL-\colTBL}}{\tmp:cnt=1}%
    \HCode{<!--cell \rowTBL,\colTBL--><td id="TBL-\TableNo-\rowTBL-\colTBL"
                \ifnum \tmp:cnt>1
                     colspan="\the\tmp:cnt"
                     style="text-align:center;"
                \fi>}%
    \let\col:TBL\colTBL
    \Configure{framed}
       {\Css{td\#TBL-\TableNo-\rowTBL-\colTBL{
                 padding-left:5pt; padding-right:5pt; border:solid black 1px;
       }}}%
       {}%
   }
   {\tmp:cnt=\colTBL
    \advance\tmp:cnt by - \col:TBL
    \ifnum \tmp:cnt>1
       \Tag{cell-\TableNo-\rowTBL-\col:TBL}{\the\tmp:cnt}%
    \fi
    \ifvmode \IgnorePar \fi \EndP
    \HCode{</td>}}
 \Css{table.bTABLE {border-spacing:0px;
            border-top: solid black 1px;
            border-bottom: solid black 1px; }}

<..context tables..>
 \Configure{table}
    {\PushStack\Table:Stck\TableNo
     \PushStack\Row:Stck\HRow     \HAssign\HRow=0\relax
     \PushStack\Col:Stck\Prev:Col
     \gHAdvance\Table:No by 1\relax
     \HAssign\TableNo=\Table:No\relax
     \ifvmode \IgnorePar\fi \EndP\halignTB{table}\putVBorder
 }
    {\HCode{</table>}%
     \PopStack\Table:Stck\TableNo
     \PopStack\Row:Stck\HRow
     \PopStack\Col:Stck\Prev:Col
    }
    {\gHAdvance\HRow by 1
     \HCode{<tr class="TBL-\TableNo-\HRow">}%
     \currentTABLEcolumn=0 \gHAssign\Prev:Col=0 }
    {\HCode{</tr>}}
    {\HAssign\HCol=\the\currentTABLEcolumn\relax
     \HAssign\HMultispan=\HCol\relax
     \HAdvance\HMultispan by -\Prev:Col\relax
     \gHAssign\Prev:Col=\HCol\relax
     \HAdvance\HCol by 1\relax
     \ifnum \HMultispan>1  \HAdvance\HCol by 1
                           \HAdvance\HCol by -\HMultispan\relax \fi
     \HCode{\Hnewline<td class="TBL-\TableNo-\HRow-\HCol" }%
     \halignTD
     \HCode{ \ifnum \HMultispan>1  colspan="\HMultispan" \fi >}%
 \gdef\dd:table{%
       \gdef\dd:table{}%
       \x:tableCell
       \d:table}%
 \def\x:tableCell{\e:tableCell \global\let\x:tableCell=\empty}%
 }
    {\HCode{</td>}}
 
 \HAssign\Table:No=0
 \HAssign\TableNo=0
 \HAssign\Prev:Col=0
 \HAssign\HRow=0
-_-_-

<..context tables..>+
 \Configure{tableCell}
    {\e:table\HCode{<div class="cell-1">}\ShowPar\par}
    {\e:table\HCode{<div class="cell-2">}\ShowPar\par}
    {\e:table\HCode{<div class="cell-3">}\ShowPar\par}
    {\e:table\HCode{<div class="cell-4">}\ShowPar\par}
    {\ifvmode \IgnorePar\fi \EndP\HCode{</div>}\f:table}
-_-_-

<..context tables..>+
 \let\VBorder\empty   \let\AllColMargins\empty
 \Configure{VBorder}
    {\let\VBorder\empty
     \let\AllColMargins\empty
     \global\let\GROUPS\empty
     \HAssign\NewGroup = 0
    }
    {%
       \let\:temp\TableNo \let\TableNo=\relax
       \edef\VBorder{\VBorder\ifnum \NewGroup> 0 </colgroup>\fi}%
       \let\TableNo\:temp
       \HAssign\NewGroup = 0
     \gdef\GROUPS{rules="groups"}%
    }
    {\Advance:\NewGroup by 1
       \let\:temp\TableNo \let\TableNo=\relax
       \ifnum \NewGroup=1 \edef\VBorder{\VBorder<colgroup
           id="TBL-\TableNo-\ar:cnt g">}\fi
       \edef\VBorder{\VBorder<col\Hnewline id="TBL-\TableNo
          -\ar:cnt"\xml:empty>}\xdef\AllColMargins{\AllColMargins1}%
       \let\TableNo\:temp
    }
    {%
       \let\:temp\TableNo \let\TableNo=\relax
       \edef\AllColMargins{\AllColMargins 0}%
       \let\TableNo\:temp
    }
 \Css{table.table td {vertical-align:top;}}
-_-_-

<..context tables..>+
 \Css{table.table td { padding-left:3pt; padding-right:3pt; }}
 
 \Configure{halignTB}{\HCode{<table }}{\HCode{>}}
 \Configure{halignTB<>}{table}{\HCode{id="TBL-\TableNo" class="table"\Hnewline
    cellspacing="0" cellpadding="0" \GROUPS\Hnewline
    }<>\HAlign}
 \Css{table[rules] {border-left:solid black 0.4pt;
                    border-right:solid black 0.4pt; }}
-_-_-

<..context tables..>+
 \Configure{TABLElongrule}{\HCode{<hr />}}
 \Configure{TableHL}
   {\TABLEnoalign{%
   \HCode{<tr>}%
 \tmp:cnt=\maxTABLEcolumn
 \advance\tmp:cnt by 2
 \HCode{<td colspan="\the\tmp:cnt"><hr /></td>}%
   \HCode{</tr>}}%
 }
-_-_-

<..context tables..>+
 \Configure{halignTD} {}{}
    {<}{\HCode{ style="white-space:nowrap; text-align:left;"}}
    {-}{\HCode{ style="white-space:nowrap; text-align:center;"}}
    {>}{\HCode{ style="white-space:nowrap; text-align:right;"}}
    {l}{\HCode{ style="white-space:nowrap; text-align:left;"}}
    {c}{\HCode{ style="white-space:nowrap; text-align:center;"}}
    {r}{\HCode{ style="white-space:nowrap; text-align:right;"}}
    {^}{\HCode{ style="vertical-align:top; white-space:nowrap;"}}
    {=}{\HCode{ style="vertical-align:baseline; white-space:nowrap;"}}
    {|}{\HCode{ style="vertical-align:middle; white-space:nowrap;"}}
    {_}{\HCode{ style="vertical-align:bottom; white-space:nowrap;"}}
    {p}{\HCode{ style="white-space:wrap; text-align:left;"}%
           \Protect\a:HColWidth}
    {m}{\HCode{ style="white-space:nowrap;
                       text-align:left; vertical-align:middle;"}}
    {b}{\HCode{ style="white-space:nowrap; text-align:left;
                       vertical-align:baseline;"}}
    {}
-_-_-

<..context index..>
 \Configure{index}
    {\Link{}{in-\nextinternalreference}\EndLink}
 \Configure{indexpage}{%
    \gHAdvance\Idx:No by 1 #1%
    {#2}%
    {#3}%
    {#4}%
    {\Link{in-#3}{}\Idx:No\EndLink}}
 \HAssign\Idx:No = 0
-_-_-

<..context index..>+
 \Configure{indexchar}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="indexchar">}}
    {\HCode{</div>}\par}
 \Css{div.indexchar{margin-top:0.2em; margin-bottom:0.1pt;}}
-_-_-

<..context index..>+
 \Configure{index-env}
    {\ifvmode \IgnorePar\fi \EndP\HCode{<div class="index-env">}\par}
    {\ifvmode \IgnorePar\fi \EndP \HCode{</div>}\par}
 \Css{div.index-env p{margin-top:0em; margin-bottom:0em;}}
 \NewConfigure{-@@idindex}{2}
-_-_-

3.8.8 letters

<..configure html4 g-brief..>
 \Configure{g-brief}
    {\ifvmode \IgnorePar\fi \EndP \HCode{<div class="g-brief">}%
     \let\sv:@imakebox\@imakebox
     \let\sv:br=\\ \def\\{\HCode{</tr><tr>}}%
     \let\:clearpage\clearpage
     \def\clearpage{\let\clearpage\:clearpage
        \ifvmode \IgnorePar\fi \EndP
        \HCode{<table class="date"><tr>}%
        \IgnorePar
     }%
     \let\brf:par\par
     \def\@imakebox[##1][##2]##3{%
       \HCode{<td class="makebox-##2">}%
       \bgroup \let\\=\sv:br \let\@imakebox\sv:@imakebox
               \let\par\sv:par
                 ##3%
       \egroup
       \HCode{</td>}%
       \def\par{\let\par\brf:par
          \ifvmode \IgnorePar\fi \EndP
          \HCode{</tr></table>}}%
     }%
    }
    {\let\\=\sv:br \let\@imakebox\sv:@imakebox
     \ifvmode \IgnorePar\fi \EndP \HCode{</div>}}
    {\ifvmode \IgnorePar\fi \EndP \HCode{<div class="end-g-brief">}}
    {\ifvmode \IgnorePar\fi \EndP \HCode{</div>}}
 \Css{table.date {width:100\%; margin-top:2em;}}
 \Css{table.date td{white-space: nowrap;}}
-_-_-

<..configure html4 g-brief..>+
 \Configure{letterfoot}
    {\ifvmode \IgnorePar\fi \EndP \HCode{<div class="letterfoot">}}
    {}
    {\HCode{</div>}}
 \Configure{letterhead}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="letterhead"><table
                            class="from"><tr><td class="name">}}
    {\HCode{</td><td class="address">}}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{</td></tr></table><div class="retouradresse">}}
    {\ifvmode \IgnorePar\fi \EndP \HCode{</div><div class="postage">}}
    {\HCode{</div></div>}}
 \Css{.letterfoot .tabular {text-align: left; margin-top:4em; }}
 \Css{table.from {width:100\%; margin-bottom:2em;}}
 \Css{table.from .address table {width:100\%;}}
 \Css{.makebox-r {text-align:right;}}
-_-_-

<..configure html4 g-brief..>+
 \Configure{datumtext}
   {\HCode{<span class="datumtext">}}
   {\HCode{</span>}}
 \Configure{datum}
   {\HCode{<span class="datum">}}
   {\HCode{</span>}\IgnorePar}
 \Configure{anrede}
   {\ifvmode \IgnorePar\fi \EndP \HCode{<div class="anrede">}}
   {\HCode{</div>}}
 \Configure{betreff}
   {\ifvmode \IgnorePar\fi \EndP\HCode{<div class="betreff">}}
   {\HCode{</div>}}
 \Css{.betreff{margin-top:2em; margin-bottom:1em;}}
 \Configure{gruss}
    {\HCode{<span class="gruss">}}
    {\HCode{</span>}}
 \Configure{unterschrift}
    {\HCode{<span class="unterschrift">}}
    {\HCode{</span>}}
 \Configure{anlagen}
    {\HCode{<span class="anlagen">}}
    {\HCode{</span>}}
 \Configure{verteiler}
    {\HCode{<span class="verteiler">}}
    {\HCode{</span>}}
 \Configure{sprache}
   {\HCode{<span class="sprache">}}
   {\HCode{</span>}}
 \Configure{telefontex}
   {\HCode{<span class="telefontex">}}
   {\HCode{</span>}}
 \Configure{telefaxtext}
   {\HCode{<span class="telefaxtext">}}
   {\HCode{</span>}}
 \Configure{telextext}
   {\HCode{<span class="telextext">}}
   {\HCode{</span>}}
 \Configure{emailtext}
   {\HCode{<span class="emailtext">}}
   {\HCode{</span>}}
 \Configure{httptext}
   {\HCode{<span class="httptext">}}
   {\HCode{</span>}}
 \Configure{banktext}
   {\HCode{<span class="banktext">}}
   {\HCode{</span>}}
 \Configure{blztext}
   {\HCode{<span class="blztext">}}
   {\HCode{</span>}}
 \Configure{betrefftext}
   {\HCode{<span class="betrefftext">}}
   {\HCode{</span>}}
 \Configure{ihrzeichentext}
   {\HCode{<span class="ihrzeichentext">}}
   {\HCode{</span>}}
 \Configure{ihrschreibentext}
   {\HCode{<span class="ihrschreibentext">}}
   {\HCode{</span>}}
 \Configure{meinzeichentext}
   {\HCode{<span class="meinzeichentext">}}
   {\HCode{</span>}}
 \Configure{unserzeichentext}
   {\HCode{<span class="unserzeichentext">}}
   {\HCode{</span>}}
 \Configure{anlagen}
   {\HCode{<span class="anlagen">}}
   {\HCode{</span>}}
 \Configure{adresse}
   {\HCode{<span class="adresse">}}
   {\HCode{</span>}}
 \Configure{bank}
   {\HCode{<span class="bank">}}
   {\HCode{</span>}}
 \Configure{blz}
   {\HCode{<span class="blz">}}
   {\HCode{</span>}}
 \Configure{email}
   {\HCode{<span class="email">}}
   {\HCode{</span>}}
 \Configure{gruss}
   {\HCode{<span class="gruss">}}
   {\HCode{</span>}}
 \Configure{grussskip}
   {\HCode{<span class="grussskip">}}
   {\HCode{</span>}}
 \Configure{http}
   {\HCode{<span class="http">}}
   {\HCode{</span>}}
 \Configure{ihrschreiben}
   {\HCode{<span class="ihrschreiben">}}
   {\HCode{</span>}}
 \Configure{ihrzeichen}
   {\HCode{<span class="ihrzeichen">}}
   {\HCode{</span>}}
 \Configure{konto}
   {\HCode{<span class="konto">}}
   {\HCode{</span>}}
 \Configure{land}
   {\HCode{<span class="land">}}
   {\HCode{</span>}}
 \Configure{meinzeichen}
   {\HCode{<span class="meinzeichen">}}
   {\HCode{</span>}}
 \Configure{name}
   {\HCode{<span class="name">}}
   {\HCode{</span>}}
 \Configure{ort}
   {\HCode{<span class="ort">}}
   {\HCode{</span>}}
 \Configure{postvermerk}
   {\HCode{<span class="postvermerk">}}
   {\HCode{</span>}}
 \Configure{retouradresse}
   {\HCode{<span class="retouradresse">}}
   {\HCode{</span>}}
 \Css{div.retouradresse { margin-bottom:2em; }}
 \Configure{strasse}
   {\HCode{<span class="strasse">}}
   {\HCode{</span>}}
 \Configure{telefax}
   {\HCode{<span class="telefax">}}
   {\HCode{</span>}}
 \Configure{telefon}
   {\HCode{<span class="telefon">}}
   {\HCode{</span>}}
 \Configure{telex}
   {\HCode{<span class="telex">}}
   {\HCode{</span>}}
 \Configure{unterschrift}
   {\HCode{<span class="unterschrift">}}
   {\HCode{</span>}}
 \Configure{verteiler}
   {\HCode{<span class="verteiler">}}
   {\HCode{</span>}}
 \Configure{zusatz}
   {\HCode{<span class="zusatz">}}
   {\HCode{</span>}}
-_-_-

3.8.9 mwcls

<..mwcls index..>
 \Configure{@begin}{theindex}{\section*{\indexname}}
 \Configure{theindex}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="theindex">}\let\end:theidx\empty}
    {\end:theidx\HCode{</div>}}
    {} {\HCode{<br />}\hfil\break}
    {\ \ \ \ } {\HCode{<br />}\hfil\break}
    {\ \ \ \ \ \ \ \ } {\HCode{<br />}\hfil\break}
    {\hbox{\end:theidx\HCode{<p class="theindex">}}%
     \def\end:theidx{\HCode{</p>}}}
-_-_-

3.8.10 Into Columns

<..book-report-article index..>
 \def\:temp#1index=#2,#3<.par del.>{%
    \ifnum #2>1 <.conf multi cols.>\fi
    \def\:temp{#2}%
 }
 \expandafter\:temp\Preamble,index=0,<.par del.>
 \ifnum \:temp<2
    <.one-col index.>
 \else
    <.mult-col index.>
 \fi
-_-_-

The \Configure{IndexColumns} instruction is to allow documents that have more than one index to employ different number of columns. The ‘index=i’ provides the initial setting.

<..one-col index..>
 \Log:Note{for i-columns index,
                use the command line option ‘index=i’ (e.g., index=2)}
 \Configure{theindex}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="theindex">}\let\end:theidx=\empty}
    {\end:theidx\HCode{</div>}}
    {\hbox\bgroup\HCode{<span class="index-item">}}
    {\HCode{<br /></span>}\egroup\hfill\break}
    {\hbox\bgroup\HCode{<span class="index-subitem">}\ \ \ \ }
    {\HCode{<br /></span>}\egroup\hfill\break}
    {\hbox\bgroup\HCode{<span class="index-subsubitem">}\ \ \ \ \ \ \ \ }
    {\HCode{<br /></span>}\egroup\hfill\break}
    {\hbox{\end:theidx\HCode{<p class="theindex">}}%
     \def\end:theidx{\HCode{</p>}}}
 \Css{.index-item, .index-subitem, .index-subsubitem {display:block}}
-_-_-

<..one-col indexOLD..>
 \Log:Note{for i-columns index,
                use the command line option ‘index=i’ (e.g., index=2)}
 \Configure{theindex}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="theindex">}\let\end:theidx=\empty}
    {\end:theidx\HCode{</div>}}
    {} {\hfil\break\HCode{<br />}}
    {\ \ \ \ } {\hfil\break\HCode{<br />}}
    {\ \ \ \ \ \ \ \ } {\hfil\break\HCode{<br />}}
    {\hbox{\end:theidx\HCode{<p class="theindex">}}%
     \def\end:theidx{\HCode{</p>}}}
-_-_-

<..conf multi cols..>
 \NewConfigure{IndexColumns}{1}
 \Configure{IndexColumns}{#2}
-_-_-

<..mult-col index..>
 \Log:Note{the number of columns
    requested by the option ‘index=\a:IndexColumns’ can
    be modified through the command \string\Configure{IndexColumns}{i}}
 \Configure{theindex}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="theindex">}%
     <.index mult cols.>\let\end:theidx=\empty}
    {\end:theidx
     <.end index mult cols.>\HCode{</div>}}
    {\hbox\bgroup\HCode{<span class="index-item">}}
    {\HCode{<br /></span>}\egroup\hfill\break}
    {\hbox\bgroup\HCode{<span class="index-subitem">}\ \ \ \ }
    {\HCode{<br /></span>}\egroup\hfill\break}
    {\hbox\bgroup\HCode{<span class="index-subsubitem">}\ \ \ \ \ \ \ \ }
    {\HCode{<br /></span>}\egroup\hfill\break}
    {%\ifvmode \EndP\fi
     % \hbox{\end:theidx\HCode{<p class="theindex">}}%
     % \def\end:theidx{\HCode{</p>}}
     \parindent=0pt
    }%
 \Css{.index-item, .index-subitem, .index-subsubitem {display:block}}
 \Css{br.index-segment:first-child {display:none}}
 \Css{.index-item br,
      .index-subitem br,
      .index-subsubitem br {display:none}}
-_-_-

<..mult-col indexOLD..>
 \Log:Note{the number of columns
    requested by the option ‘index=\a:IndexColumns’ can
    be modified through the command \string\Configure{IndexColumns}{i}}
 \Configure{theindex}
    {\ifvmode \IgnorePar\fi \EndP
     \HCode{<div class="theindex">}%
     <.index mult cols.>\let\end:theidx=\empty}
    {\end:theidx
     <.end index mult cols.>\HCode{</div>}}
    {} {\hfil\break\HCode{<br />}}
    {\ \ \ \ } {\hfil\break\HCode{<br />}}
    {\ \ \ \ \ \ \ \ } {\hfil\break\HCode{<br />}}
    {%\ifvmode \EndP\fi
     % \hbox{\end:theidx\HCode{<p class="theindex">}}%
     % \def\end:theidx{\HCode{</p>}}
     \parindent=0pt
    }%
-_-_-

<..index mult cols..>
 \Configure{HColumns}
      {\IgnorePar\EndP
          \HCode{<table \Hnewline class="index" width="100\%"
                      cellspacing="15"><tr style="vertical-align:top;">}}
      {\HCode{</tr></table>}}
      {\HCode{<td>}\ColMag{1.1}}
      {\IgnorePar\EndP\HCode{</td>}}
   \HColumns{\a:IndexColumns}%
   \everypar{\HtmlPar}%
   \Configure{HtmlPar}{}{\HCode{<br class="index-segment" />}}{}{}%
   \par\ShowPar
-_-_-

<..end index mult cols..>
 \ifvmode\IgnorePar\fi \EndP\EndHColumns
-_-_-

<..mult-col index..>+
 \def\add:col{\Advance:\:cols  -1 \HAdvance\HCol  1\relax
    \ifnum \:cols>0
       \c:Cols \vsplit0 to \tmp:dim  \d:Cols  \expandafter\add:col
    \fi}
 \NewConfigure{HColumns}{4}
 \def\c:Cols{\edef\sv:dim{\the\tmp:dim}\c:HColumns}
 \def\d:Cols{\d:HColumns \tmp:dim\sv:dim }
 \def\ColMag#1{\tmp:dim  #1\tmp:dim}
 \def\HColumns#1{%
    \a:HColumns
    \HAssign\:cols#1  \setbox0=\vbox\bgroup
    \divide\hsize  #1  }
 \def\EndHColumns{\egroup   \HAssign\HCol0
   \tmp:dim\ht0  \advance\tmp:dim  \dp0  \divide\tmp:dim  \:cols
   \add:col \c:Cols \box0 \d:Cols \b:HColumns}
-_-_-