This parameter asks for a pure text-based output without hypertext tags.
try.html 1 a demonstration of how 2 to produce xml output. | %-- try.tex -- \documentclass{article} \usepackage[html,0.0]{tex4ht} \begin{document} \section{a demonstration} of how \section{to produce} xml output. \end{document} |
This parameter asks for pseudo hypertext tags that partially trace empty parameters of configuration instructions. The pseudo tags are highlighted fragments of content in the output, which carry the look of tags.
<HTML1:2>
<HEAD1:2>
<TITLE1:2>
<HtmlPar2:4>
try.html<TITLE2:2><HEAD2:2><BODY1:2>
<TocAt1:2>
<TocAt2:2>
<HtmlPar2:4> 1 <toc1:1>a
demonstration<section3:4>
<TocAt1:2>
<TocAt2:2>
<HtmlPar2:4> of how
<TocAt1:2>
<TocAt2:2>
<section2:4>
2 <toc1:1>to produce<section3:4>
<TocAt1:2>
<TocAt2:2>
<HtmlPar2:4> xml output.
<section2:4><BODY2:2><HTML2:2>
| %-- try.tex -- \documentclass{article} \usepackage[html,0.0]{tex4ht} \begin{document} \section{a demonstration} of how \section{to produce} xml output. \end{document} |
For instance, in the above example, the fields `<section2:4>
' and `<section3:4>
' indicate that
`\Configuration{section}
' should have four parameters. Moreover, the location of `<section2:4>
' shows where
the content of the second parameter will be included, and the location of `<section3:4>
' shows where the content of
the third parameter will be included. A little experimentation reveals that the above configuration command has the
following meaning.
\Configuration{section} {before-section} {after-section} {before-title} {after-title}
<HTML1:2>
<HEAD1:2>
<TITLE1:2>
<HtmlPar2:4>
try.html<TITLE2:2><HEAD2:2><BODY1:2>
<TocAt1:2>
<TocAt2:2>
<HtmlPar2:4> <toc1:1>a demonstration<TocAt1:2> <TocAt2:2> <HtmlPar2:4> of how <TocAt1:2> <TocAt2:2><toc1:1>to produce<TocAt1:2> <TocAt2:2> <HtmlPar2:4> xml output. <BODY2:2><HTML2:2> | %---- try.tex ---- \documentclass{article} \usepackage[try,html]{tex4ht} \begin{document} \section{a demonstration} of how \section{to produce} xml output. \end{document} %---- try.cfg ---- \Preamble{0.0,hooks} \Configure{section} {\HCode{<HR>}} {\empty} {\HCode{<H3>}} {\HCode{</H3>}} \begin{document} \EndPreamble |
Most configurations should be set after the \Preamble
command, but a few must appear earlier. Again, a little
experimentation is probably the easiest approach for detecting the latter exceptions.
<HTML1:2>
<HEAD1:2>
<TITLE1:2>
<HtmlPar2:4>
try.html<TITLE2:2><HEAD2:2><BODY1:2>
a demonstrationof how to producexml output. <BODY2:2><HTML2:2> | %---- try.cfg ---- \Configure{HtmlPar} {\HCode{<P>}}{\HCode{<P>}} {\empty}{\empty} \Preamble{0.0,hooks} \Configure{section} {\HCode{<HR>}} {\empty} {\HCode{<H3>}} {\HCode{</H3>}} \Configure{TocAt}{\empty}{\empty} \Configure{TocAt>}{\empty}{\empty} \Configure{toc}{\empty} \begin{document} \EndPreamble |
This option is a generalization of the previous one. It adds to the log
file a partial tracing of \Configuration
instructions.
The three commands introduce start, end, and empty, pseudo hypertext tags to the output. The edit parameter request abstract forms of the hypertext tags.
<TITLE>try.html</TITLE>
<HR><H3> a demonstration</H3> of how <HR><H3> to produce</H3> xml output. | %---- try.cfg ---- \Configure{HtmlPar} {\HCode{<P>}}{\HCode{<P>}} {}{} \Configure{TITLE} {\Tg<TITLE>}{\Tg</TITLE>} \Preamble{0.0,edit} \Configure{section} {\Tg<HR>} {\empty} {\Tg<H3>} {\Tg</H3>} \Configure{TocAt}{\empty}{\empty} \Configure{TocAt>}{\empty}{\empty} \Configure{toc}{\empty} \begin{document} \EndPreamble |
The \Tg
commands allow also for arguments in their content.
The pseudo tags produced by the \Tg
commands are easier to program when the `hooks
' parameter is also
present, due to the hints provided by the pseudo tags. The current commands allow to provide distinguished looks
to the corresponding pseudo tags.
<HTML1:2>
<HEAD1:2>
<HtmlPar2:4>
<HtmlPar2:4>
<FILE>try.html</FILE><HEAD2:2><BODY1:2>
<SECTION><TITLE> a demonstration</TITLE> of how </SECTION><SECTION><TITLE> to produce</TITLE> xml output. </SECTION><BODY2:2><HTML2:2> | %---- try.cfg ---- \Configure{HtmlPar} {\HCode{<P>}}{\HCode{<P>}} {}{} \Configure{TITLE} {\Tg<FILE>}{\Tg</FILE>} \Preamble{0.0,edit,hooks} \Configure{section} {\Tg<SECTION>} {\Tg</SECTION>} {\Tg<TITLE>} {\Tg</TITLE>} \Configure{toc}{\empty} \Configure{TocAt}{\empty}{\empty} \Configure{TocAt>}{\empty}{\empty} \Configure{hooks} {\HCode{<SPAN CLASS="hooks"><}} {\HCode{></SPAN>}} {}{} \begin{document} \Css .hooks{ color : green ; } \EndCss \EndPreamble |
These commands configure the appearance of the pseudo tags introduced, respectively, by the commands
\Tg<...>
, \Tg</...>
, and \Tg<.../>
(when the `edit
' parameter is present).
<FILE>try.html</FILE>
<SECTION> <TITLE> a demonstration</TITLE> of how </SECTION> <SECTION> <TITLE> to produce</TITLE> xml output. </SECTION> | %---- try.cfg ---- \Configure{HtmlPar} {}{} {}{} \Configure{TITLE} {\Tg<FILE>}{\Tg</FILE>} \Preamble{0.0,edit} \Configure{section} {\Tg<SECTION>} {\EndP\Tg</SECTION>} {\Tg<TITLE>} {\Tg</TITLE>} \Configure{toc}{\empty} \Configure{TocAt}{\empty}{\empty} \Configure{TocAt>}{\empty}{\empty} \Configure<SECTION>{\HCode{<BR>}}{\HCode{<BR>}} \Configure</SECTION>{\HCode{<BR>}}{\HCode{<BR>}} \begin{document} \EndPreamble |
These variants of the \Configure
command specify replacements for tags created by the \Tg
command. They
allow to provide counter HTML representations for the XML documents being compiled from the source LaTeX
files.
<!--try.html--> <H2> a demonstration</H2> of how <H2> to produce</H2> xml output. | %---- try.cfg ---- \Configure{HtmlPar} {}{} {}{} \Configure{TITLE} {\Tg<FILE>}{\Tg</FILE>} \Preamble{0.0,edit} \Configure{section} {\Tg<SECTION>} {\EndP\Tg</SECTION>} {\Tg<TITLE>} {\Tg</TITLE>} \Configure{toc}{\empty} \Configure{TocAt}{\empty}{\empty} \Configure{TocAt>}{\empty}{\empty} \Configure<SECTION>+{} \Configure</SECTION>+{} \Configure<TITLE>+{\HCode{<H2>}} \Configure</TITLE>+{\HCode{</H2>}} \Configure<FILE>+{\HCode{<!--}} \Configure</FILE>+{\HCode{-->}} \begin{document} \EndPreamble |
edit
' parameter, which introduces configuration information into the
log file.
The current parameter asks for a warning message to be given for unknown containment relationships of tags
defined by \Tg
. A containment relationship can be made known to the system, by inserting into the environment
`\Verify...\EndVerify
' the parent and child pair separated by the string `-->
'. Commas should be used to
separate pairs in the listing.
<DOC> <FILE>try.html</FILE>
<SECTION><TITLE> a
demonstration</TITLE>
of how
</SECTION><SECTION><TITLE>
to produce</TITLE>
xml output. </SECTION></DOC>
| %---- try.cfg ---- \Configure{HtmlPar} {}{} {}{} \Configure{TITLE} {\Tg<FILE>}{\Tg</FILE>} \Configure{HTML} {\Tg<DOC>}{\Tg</DOC>} \Preamble{0.0,edit,verify} \Configure{section} {\Tg<SECTION>} {\EndP\Tg</SECTION>} {\Tg<TITLE>} {\Tg</TITLE>} \Configure{toc}{\empty} \Configure{TocAt}{\empty}{\empty} \Configure{TocAt>}{\empty}{\empty} \Verify --> DOC, DOC --> FILE, DOC --> SECTION \EndVerify \begin{document} \EndPreamble |
The compilation of the LaTeX file that produced the last example, issued the warning message `6. ---
warning --- SECTION --> TITLE ?
'.
This is a variant of the `verify
' parameter that reports in the `log
' file the detected containment
relations.