Frank Gevaerts | 9d160c2 | 2015-01-08 17:44:44 +0100 | [diff] [blame] | 1 | % scrreprt.4ht (2014-07-15-16:10), generated from tex4ht-4ht.tex |
| 2 | % Copyright (C) 1999--2009 Eitan M. Gurari |
| 3 | % 2009--2014 TeX Users Group |
| 4 | % |
| 5 | % This work may be distributed and/or modified under the |
| 6 | % conditions of the LaTeX Project Public License, either |
| 7 | % version 1.3c of this license or (at your option) any |
| 8 | % later version. The latest version of this license is in |
| 9 | % http://www.latex-project.org/lppl.txt |
| 10 | % and version 1.3c or later is part of all distributions |
| 11 | % of LaTeX version 2005/12/01 or later. |
| 12 | % |
| 13 | % This work has the LPPL maintenance status "maintained". |
| 14 | % |
| 15 | % The Current Maintainer of this work |
| 16 | % is the TeX4ht Project <http://tug.org/tex4ht>. |
| 17 | % |
| 18 | % If you modify this program, changing the |
| 19 | % version identification would be appreciated. |
| 20 | \immediate\write-1{version 2014-07-15-16:10} |
| 21 | |
| 22 | \let\o:maketitle:\maketitle |
| 23 | \def\maketitle{\bgroup |
| 24 | \gHAdvance\:mpNum by 1 |
| 25 | \HAssign\minipageNum=\:mpNum \relax |
| 26 | % |
| 27 | \ifx \EndPicture\:UnDef |
| 28 | \def\sec:typ{title}% |
| 29 | \Configure{HtmlPar}{}{}{}{}% |
| 30 | \Configure{newpage}{}% |
| 31 | \ConfigureEnv{center}{\empty}{}{\empty}{\empty} |
| 32 | \let\a:tabular:sv\a:tabular \let\b:tabular:sv\b:tabular |
| 33 | \let\c:tabular:sv\c:tabular \let\d:tabular:sv\d:tabular |
| 34 | \let\e:tabular:sv\e:tabular \let\f:tabular:sv\f:tabular |
| 35 | \let\before:begintabular:sv\before:begintabular |
| 36 | % |
| 37 | \Configure{HBorder}{}{}{}{}{}{}{}{}{}{}% |
| 38 | \Configure{tabular}{}{}{}{\e:mktl} |
| 39 | {\bgroup \let\a:tabular\a:tabular:sv \let\b:tabular\b:tabular:sv |
| 40 | \let\c:tabular\c:tabular:sv \let\d:tabular\d:tabular:sv |
| 41 | \let\e:tabular\e:tabular:sv \let\f:tabular\f:tabular:sv |
| 42 | \let\before:begintabular\before:begintabular:sv |
| 43 | }{\egroup} |
| 44 | \ConfigureEnv{tabular}{\empty}{}{}{}% |
| 45 | % |
| 46 | \pend:def\@title{\a:ttl}\append:def\@title{\b:ttl}% |
| 47 | \pend:def\@date{\a:date}\append:def\@date{\b:date}% |
| 48 | \pend:def\@author{\a:author}\append:def\@author{\b:author}% |
| 49 | \def\and{\a:and} |
| 50 | % |
| 51 | \fi |
| 52 | \pic:gobble\a:mktl \o:maketitle: \pic:gobble\b:mktl |
| 53 | \egroup \let\maketitle\empty} |
| 54 | \NewConfigure{maketitle}[4]{\c:def\a:mktl{#1}\c:def\b:mktl{#2}% |
| 55 | \c:def\a:ttl{#3}\c:def\b:ttl{#4}} |
| 56 | \NewConfigure{thanks author date and}[8]{% |
| 57 | \c:def\a:thanks{#1}\c:def\b:thanks{#2}\c:def\a:author{#3}\c:def\b:author{#4}% |
| 58 | \c:def\a:date{#5}\c:def\b:date{#6}\c:def\a:and{#7}\c:def\e:mktl{#8}} |
| 59 | |
| 60 | \pend:def\titlepage{% |
| 61 | \cfg:maketitle |
| 62 | } |
| 63 | \def\cfg:maketitle{% |
| 64 | \global\let\cfg:maketitle\empty |
| 65 | \ifx\@dedication\@empty \else |
| 66 | \pend:def\@dedication{\a:dedication}% |
| 67 | \append:def\@dedication{\b:dedication}% |
| 68 | \fi |
| 69 | } |
| 70 | \NewConfigure{dedication}{2} |
| 71 | |
| 72 | \Configure{UndefinedSec}{likepart} |
| 73 | \Configure{UndefinedSec}{likechapter} |
| 74 | \Configure{UndefinedSec}{likesection} |
| 75 | \Configure{UndefinedSec}{likesubsection} |
| 76 | \def\tableofcontents{% |
Frank Gevaerts | 9d160c2 | 2015-01-08 17:44:44 +0100 | [diff] [blame] | 77 | \:tableofcontents} |
| 78 | |
| 79 | |
| 80 | \let\:tempb\chapter |
| 81 | \Def:Section\chapter{\thechapter}{#1} |
| 82 | \let\:chapter\chapter |
| 83 | \let\chapter\:tempb |
| 84 | \def\@makechapterhead#1{} |
| 85 | \let\no@chapter\@chapter |
| 86 | \def\@chapter[#1]#2{% |
| 87 | \gHAdvance\:mpNum by 1 |
| 88 | \HAssign\minipageNum=\:mpNum \relax |
| 89 | % |
| 90 | {\SkipRefstepAnchor \let\addcontentsline\:gobbleIII\no@chapter[#1]{}}% |
| 91 | \HtmlEnv \Toc:Title{#1}\:chapter{#2}} |
| 92 | \Def:Section\likechapter{}{#1} |
| 93 | \let\:likechapter\likechapter |
| 94 | \let\likechapter\:UnDef |
| 95 | \let\no@schapter\@schapter |
| 96 | \def\@schapter#1{% |
| 97 | {\let\addcontentsline\:gobbleIII\no@schapter{}}% |
| 98 | \HtmlEnv \:likechapter{#1}} |
| 99 | \let\no@appendix\appendix |
| 100 | \Def:Section\appendix{\thechapter}{#1} |
| 101 | \let\:appendix\appendix |
| 102 | \def\appendix{% |
| 103 | \def\@chapter[##1]##2{% |
| 104 | \gHAdvance\:mpNum by 1 |
| 105 | \HAssign\minipageNum=\:mpNum \relax |
| 106 | % |
| 107 | {\def\addcontentsline####1####2####3{}\no@chapter[##1]{}}% |
| 108 | \HtmlEnv \Toc:Title{##1}\:appendix{##2}}% |
| 109 | \no@appendix} |
| 110 | |
| 111 | \NewConfigure{caption}[4]{\c:def\cptA:{#1}\c:def\cptB:{#2}% |
| 112 | \c:def\cptC:{#3}\c:def\cptD:{#4}} |
| 113 | \long\def\@makecaption#1#2{% |
| 114 | {\cptA: \cap:ref{#1}% |
| 115 | \cptB:}{\cptC:{#2}\cptD:}} |
| 116 | |
| 117 | |
| 118 | \pend:def\caption{\SkipRefstepAnchor} |
| 119 | \append:def\quote{\par\@totalleftmargin\z@} |
| 120 | \long\def\c:theindex:#1#2#3#4#5#6#7#8#9{% |
| 121 | \def\theindex{% |
| 122 | \def\idx:item{\SaveEverypar\ht:everypar{}#1}% |
| 123 | \def\endtheindex{\idx:item#2\RecallEverypar}% |
| 124 | \def\item{\idx:item\def\idx:item{#4}\let\index\@gobble #3}% |
| 125 | \def\subitem{\idx:item\def\idx:item{#6}\let\index\@gobble #5}% |
| 126 | \def\subsubitem{\idx:item\def\idx:item{#8}\let\index\@gobble #7}}% |
| 127 | \def\indexspace{\idx:item#9\let\idx:item\empty}} |
| 128 | \def\warn:idx#1{% |
| 129 | \expandafter\ifx \csname #1warn:idx\endcsname\relax |
| 130 | \expandafter\global |
| 131 | \expandafter\let \csname #1warn:idx\endcsname\def |
| 132 | \immediate\write16 |
| 133 | {---------------------------------------------------------}% |
| 134 | \:warning{If not done so, the index is to be processed by |
| 135 | ^^J\space\space tex '\string\def\string\filename |
| 136 | {{#1}{idx}{4dx}{ind}} \noexpand\input\space idxmake.4ht' |
| 137 | ^^J\space\space makeindex -o #1.ind #1.4dx |
| 138 | ^^Jinstead of |
| 139 | ^^J\space\space makeindex -o #1.ind #1.idx |
| 140 | ^^JOn some platforms, the quotation marks ' should be |
| 141 | ^^J replaced by double quotation marks " or eliminated. |
| 142 | ^^J--------------------------------------------------------- |
| 143 | }% |
| 144 | {\Configure{Needs}{File: #1.4idx}\Needs{}}% |
| 145 | \fi} |
| 146 | \ifOption{info}{\Log:Note{ |
| 147 | A script of the form |
| 148 | ^^Jtex '\def\string\filename{{\%\%1}{idx}{4dx}{ind}} |
| 149 | \string\input\space idxmake.4ht' |
| 150 | ^^Jmakeindex -o \%\%1.ind \%\%1.4dx |
| 151 | ^^Jin the env file, automatically calls to the revised makeindex |
| 152 | ^^Jcommand. An extra compilation of the source LaTeX file is required, |
| 153 | ^^Jto get the index correctly into the output.}}{} |
| 154 | \def\ind:defs{\let\LNKidx\empty |
| 155 | \def\LNK##1##2##3##4{\ifx\NewConfigure\:UnDef\else |
| 156 | \def\LNK:number{##4}% |
| 157 | \a:LNK[##1]{##2}{}\gHAdvance\:LNKno1 |
| 158 | \def\:THIrd{##3}\ifx\:THIrd\empty |
| 159 | \LNKidx{\ifx\c:LNK\empty\:LNKno\else \c:LNK\fi}\else |
| 160 | \LNKidx{##3}\fi |
| 161 | \global\let\LNKidx\empty |
| 162 | \b:LNK |
| 163 | \fi}% |
| 164 | \def\:LNKno{0}} |
| 165 | \NewConfigure{LNK}{3} |
| 166 | \Configure{LNK}{\Link}{\EndLink}{} |
| 167 | \def\yhbLNK#1{\expandafter\let\expandafter\LNKidx\csname |
| 168 | #1\endcsname\LNK} |
| 169 | |
| 170 | \Configure{@begin}{theindex}{\ind:defs} |
| 171 | |
| 172 | \NewConfigure{maketitle}[4]{\c:def\a:mktl{#1}\c:def\b:mktl{#2}% |
| 173 | \c:def\a:ttl{#3}\c:def\b:ttl{#4}} |
| 174 | \NewConfigure{thanks author date and}[8]{% |
| 175 | \c:def\a:thanks{#1}\c:def\b:thanks{#2}% |
| 176 | \c:def\a:author{#3}\c:def\b:author{#4}% |
| 177 | \c:def\a:date{#5}\c:def\b:date{#6}\c:def\a:and{#7}\c:def\e:mktl{#8}} |
| 178 | |
| 179 | |
| 180 | \append:def\quotation{\a:quotation\par\@totalleftmargin\z@} |
| 181 | \NewConfigure{quotation}{1} |
| 182 | \NewConfigure{listof}{6} |
| 183 | |
| 184 | \def\tableofcontents{% |
Frank Gevaerts | 9d160c2 | 2015-01-08 17:44:44 +0100 | [diff] [blame] | 185 | \:tableofcontents} |
| 186 | |
| 187 | \edef\:TOC{% |
| 188 | \noexpand\ifx [\noexpand\:temp |
| 189 | \noexpand\expandafter\noexpand\:TableOfContents |
| 190 | \noexpand\else |
| 191 | \noexpand\Auto:ent{\ifnum \c@tocdepth >-2 part,\fi |
| 192 | \ifnum \c@tocdepth >\m@ne chapter,appendix,addchap,\fi |
| 193 | \ifnum \z@>\c@tocdepth\else section,\fi |
| 194 | \ifnum 1>\c@tocdepth \else subsection,\fi |
| 195 | \ifnum 2>\c@tocdepth \else subsection,\fi |
| 196 | \ifnum 3>\c@tocdepth \else subsubsection,\fi |
| 197 | \ifnum 4>\c@tocdepth \else paragraph,\fi |
| 198 | \ifnum 5>\c@tocdepth \else subparagraph,\fi |
| 199 | UnDFexyz}% |
| 200 | \noexpand\fi} |
| 201 | \def\:tableofcontents{\futurelet\:temp\:TOC} |
| 202 | \def\Auto:ent#1{% |
| 203 | \edef\auto:toc{\noexpand\:TableOfContents[\ifx \auto:toc\:UnDef |
| 204 | #1\else \auto:toc \fi]} \auto:toc |
| 205 | \global\let\auto:toc\:UnDef } |
| 206 | \def\:tocs{\noexpand\:tableofcontents} |
| 207 | \pend:defIII\addcontentsline{% |
| 208 | \def\:temp{##1}\def\:tempa{toc}\ifx \:temp\:tempa |
| 209 | \gHAdvance\TitleCount 1 \fi } |
| 210 | \def\@dottedtocline#1#2#3#4#5{\hbox{\def\numberline##1{\e:listof |
| 211 | ##1\f:listof}\c:listof#4\d:listof}\ignorespaces} |
| 212 | \def\@starttoc#1{% |
| 213 | \begingroup |
| 214 | \makeatletter \Configure{cite}{}{}{}{}% |
| 215 | \def\:temp{#1}\def\:tempa{toc}% |
| 216 | \a:listof\par |
| 217 | \@input{\jobname.\ifx \:temp\:tempa 4ct\else #1\fi}% |
| 218 | \b:listof |
| 219 | \if@filesw |
| 220 | \expandafter\expandafter\csname |
| 221 | newwrite\endcsname\csname tf@#1\endcsname |
| 222 | \immediate\openout \csname tf@#1\endcsname \jobname.#1\relax |
| 223 | \fi |
| 224 | \global\@nobreakfalse |
| 225 | \endgroup} |
| 226 | \NewConfigure{tableofcontents*}[1]{% |
| 227 | \def\:tempa{#1}\ifx\empty\:tempa |
| 228 | \ifx \au:StartSec\:UnDef \else \gdef\:StartSec{\au:StartSec}\fi |
| 229 | \else |
| 230 | \edef\auto:toc{#1}% |
| 231 | \ifx \au:StartSec\:UnDef |
| 232 | \let\au:StartSec\:StartSec |
| 233 | \def\:StartSec{\:tableofcontents |
| 234 | \global\let\auto:toc\:UnDef \:StartSec}% |
| 235 | \pend:def\:tableofcontents{\gdef\:StartSec{\au:StartSec}}% |
| 236 | \fi \fi |
| 237 | } |
| 238 | |
| 239 | |
| 240 | \ifx \@openbib@code\:UnDef \else |
| 241 | \pend:def\@openbib@code{\labelsep\z@} |
| 242 | \fi |
| 243 | \def\:temp#1#2!*?: {\def\:temp{#1}} |
| 244 | \expandafter\:temp\usepackage!*?: |
| 245 | \def\:tempa{\@latex@e@error} |
| 246 | \ifx \:temp\:tempa \else |
| 247 | \def\popthree#1#2#3#4{#4} |
| 248 | \def\:tempa#1#2#3#4{\tmp:toks{#1{#2}}% |
| 249 | \long\expandafter\edef\csname #4 \endcsname{\the\tmp:toks |
| 250 | {\expandafter\noexpand |
| 251 | \csname o:\expandafter\expandafter\:gobble\expandafter\string \popthree#3:\endcsname}}} |
| 252 | \def\:temp#1{% |
| 253 | \expandafter\expandafter\expandafter\:tempa\csname #1 \endcsname{#1}} |
| 254 | \:temp{rm} |
| 255 | \:temp{sf} |
| 256 | \:temp{tt} |
| 257 | \:temp{bf} |
| 258 | \:temp{it} |
| 259 | |
| 260 | \fi |
| 261 | \let\:tempc\listoffigures |
| 262 | \pend:def\:tempc{\begingroup \a:listoffigures |
| 263 | \def\@starttoc{\:tableofcontents[lof]\:gobble}} |
| 264 | \append:def\:tempc{\b:listoffigures \endgroup} |
| 265 | \HLet\listoffigures\:tempc |
| 266 | \let\:tempc\listoftables |
| 267 | \pend:def\:tempc{\begingroup \a:listoftables |
| 268 | \def\@starttoc{\:tableofcontents[lot]\:gobble}} |
| 269 | \append:def\:tempc{\b:listoftables \endgroup} |
| 270 | \HLet\listoftables\:tempc |
| 271 | |
| 272 | \NewConfigure{listoffigures}{2} |
| 273 | \NewConfigure{listoftables}{2} |
| 274 | |
| 275 | \ifx \part\:UnDef\else |
| 276 | \def\@part[#1]#2{% |
| 277 | \ifnum \c@secnumdepth >-2\relax |
| 278 | \SkipRefstepAnchor \refstepcounter{part}% |
| 279 | \addcontentsline{toc}{part}{\thepart\hspace{1em}#1}% |
| 280 | \else |
| 281 | \addcontentsline{toc}{part}{#1}% |
| 282 | \fi |
| 283 | \csname @endpart\endcsname} |
| 284 | \let\:tempb\part |
| 285 | \Def:Section\part{\thepart}{#1} |
| 286 | \let\:part\part |
| 287 | \let\part\:tempb |
| 288 | \let\no@part\@part |
| 289 | \def\@part[#1]#2{% |
| 290 | {\let\addcontentsline\:gobbleIII\no@part[#1]{}}% |
| 291 | \HtmlEnv \Toc:Title{#1}\:part{#2}} |
| 292 | \Def:Section\likepart{}{#1} |
| 293 | \let\:likepart\likepart |
| 294 | \let\likepart\:UnDef |
| 295 | \let\no@spart\@spart |
| 296 | \def\@spart#1{% |
| 297 | {\let\addcontentsline\:gobbleIII\no@spart{}}% |
| 298 | \HtmlEnv \:likepart{#1}} |
| 299 | |
| 300 | \fi |
| 301 | \ifx \section\:UnDef\else |
| 302 | \let\no@section\section |
| 303 | \Def:Section\section{\ifnum \c:secnumdepth>\c@secnumdepth \else |
| 304 | \thesection \fi}{#1} |
| 305 | \let\no:section\section |
| 306 | \def\section{\rdef:sec{section}} |
| 307 | \Def:Section\likesection{}{#1} |
| 308 | \let\:likesection\likesection |
| 309 | \let\likesection\:UnDef |
| 310 | \fi |
| 311 | \let\no@subsection\subsection |
| 312 | \Def:Section\subsection{\ifnum \c:secnumdepth>\c@secnumdepth \else |
| 313 | \thesubsection \fi}{#1} |
| 314 | \let\no:subsection\subsection |
| 315 | \def\subsection{\rdef:sec{subsection}} |
| 316 | \Def:Section\likesubsection{}{#1} |
| 317 | \let\:likesubsection\likesubsection |
| 318 | \let\likesubsection\:UnDef |
| 319 | \let\no@subsubsection\subsubsection |
| 320 | \Def:Section\subsubsection{\ifnum \c:secnumdepth>\c@secnumdepth \else |
| 321 | \thesubsubsection \fi}{#1} |
| 322 | \let\no:subsubsection\subsubsection |
| 323 | \def\subsubsection{\rdef:sec{subsubsection}} |
| 324 | \Def:Section\likesubsubsection{}{#1} |
| 325 | \let\:likesubsubsection\likesubsubsection |
| 326 | \let\likesubsubsection\:UnDef |
| 327 | \let\no@paragraph\paragraph |
| 328 | \Def:Section\paragraph{\ifnum \c:secnumdepth>\c@secnumdepth \else |
| 329 | \theparagraph \fi}{#1} |
| 330 | \let\no:paragraph\paragraph |
| 331 | \def\paragraph{\rdef:sec{paragraph}} |
| 332 | \Def:Section\likeparagraph{}{#1} |
| 333 | \let\:likeparagraph\likeparagraph |
| 334 | \let\likeparagraph\:UnDef |
| 335 | \let\no@subparagraph\subparagraph |
| 336 | \Def:Section\subparagraph{\ifnum \c:secnumdepth>\c@secnumdepth \else |
| 337 | \thesubparagraph \fi}{#1} |
| 338 | \let\no:subparagraph\subparagraph |
| 339 | \def\subparagraph{\rdef:sec{subparagraph}} |
| 340 | \Def:Section\likesubparagraph{}{#1} |
| 341 | \let\:likesubparagraph\likesubparagraph |
| 342 | \let\likesubparagraph\:UnDef |
| 343 | \ConfigureToc{likeparagraph} {}{\empty}{}{\newline} |
| 344 | \ConfigureToc{likepart} {}{\empty}{}{\newline} |
| 345 | \ConfigureToc{likesection} {}{\empty}{}{\newline} |
| 346 | \ConfigureToc{likesubparagraph} {}{\empty}{}{\newline} |
| 347 | \ConfigureToc{likesubsection} {}{\empty}{}{\newline} |
| 348 | \ConfigureToc{likesubsubsection} {}{\empty}{}{\newline} |
| 349 | \ConfigureToc{paragraph} {\empty}{\ }{}{\newline} |
| 350 | \ConfigureToc{part} {\empty}{\ }{}{\newline} |
| 351 | \ConfigureToc{section} {\empty}{\ }{}{\newline} |
| 352 | \ConfigureToc{subparagraph} {\empty}{\ }{}{\newline} |
| 353 | \ConfigureToc{subsection} {\empty}{\ }{}{\newline} |
| 354 | \ConfigureToc{subsubsection} {\empty}{\ }{}{\newline} |
| 355 | \ConfigureToc{appendix} {\empty}{\ }{}{\newline} |
| 356 | \ConfigureToc{chapter} {\empty}{\ }{}{\newline} |
| 357 | \ConfigureToc{likechapter} {}{\empty}{}{\newline} |
| 358 | |
| 359 | \ifx \@@maybeautodot\:UnDef |
| 360 | \let\add:chap=\@addchap |
| 361 | \def\@addchap{% |
| 362 | \let\chap:addcontentsline=\addcontentsline |
| 363 | \def\addcontentsline{\let\addcontentsline\chap:addcontentsline |
| 364 | \:gobbleIII }% |
| 365 | \add:chap} |
| 366 | |
| 367 | \else |
| 368 | \let\no@addchap\@addchap |
| 369 | \def\@addchap[#1]#2{% |
| 370 | \HtmlEnv \Toc:Title{#1}\:addchap{#2}} |
| 371 | |
| 372 | \fi |
| 373 | \let\:makeschapterhead=\@makeschapterhead |
| 374 | \def\::makeschapterhead#1{\:makeschapterhead{\normalfont\normalsize |
| 375 | \:addchap {#1}}} |
| 376 | \pend:def\addchap{\let\@makeschapterhead\::makeschapterhead} |
| 377 | \pend:def\chapter{\let\@makeschapterhead\:makeschapterhead} |
| 378 | \let\:tempb=\addchap |
| 379 | \Def:Section\addchap{}{#1} |
| 380 | \let\:addchap=\addchap |
| 381 | \let\addchap=\:tempb |
| 382 | \ConfigureToc{addchap} {\empty}{\ }{}{\newline} |
| 383 | |
| 384 | \Def:Section\minisec{}{#1} |
| 385 | \let\:minisec=\minisec |
| 386 | \def\minisec#1{\:minisec{#1}\@afterheading} |
| 387 | \pend:defI\@makefntext{\IgnorePar} |
| 388 | |
| 389 | \Hinput{scrreprt} |
| 390 | \endinput |
| 391 | |