next up previous contents index
Next: Active Image Maps Up: No Title Previous: Cross-Referencing Example

Miscellaneous commands for HTML effects  

 

The html package, through the LATEX input file html.sty, and its Perl counterpart html.perl, implements several new commands that are intended entirely for effects within the produced HTML files. In LATEX these commands, their arguments, and any optional arguments are completely ignored.

  

\htmlrule and \htmlrule*  

One such device provided by html.sty, is the \htmlrule command. This puts a horizontal rule into the HTML file only; being ignored in the .dvi version. It is useful to provide extra visual separation between paragraphs, without creating a new HTML page, such as might warrant extra vertical space within the printed version.

   
change_begin97.1
Much variation can be obtained in the horizontal rule that is produced, using extended forms of the \htmlrule command:

\htmlrule
\htmlrule*
\htmlrule[<attribs>]
\htmlrule*[<attribs>]
Whereas a ``break'' tag <BR> normally precedes the <HR> generated by the \htmlrule command, this break is omitted when using the \htmlrule* variant.



Furthermore, the optional argument <attribs> can be used to specify attributes for both the <HR> and <BR> tags. More specifically, <attribs> should be a list of attribute-names and/or key-value pairs <key>=<value> separated by spaces or commas. This list is parsed to extract those attributes applicable to the <HR> tag, and those applicable to the <BR> (with the unstarred variant).




Using HTML 3.2, this allows variations to be specified for:

Some examples of these effects appear on this page.
change_end 97.1

 

  
\strikeout{<text>}


change_begin97.1
With this command the <text> is processed as normal in the HTML version, then placed between <STRIKE>...</STRIKE> tags. Thus a horizontal line should be drawn through the middle of the <text>.
Currently the command and the <text> are ignored in the LATEX version.
change_end 97.1

 

\tableofchildlinks  


change_begin97.1
As an extra aid to navigation within a long page, containing several (sub)subsections or deeper levels of sectioning, there is the \tableofchildlinks command. This does not generate anything new, for a table of the child links on or from a page is generated automatically by LATEX2HTML.

However if this command, or its variant \tableofchildlinks*, occurs within the source code to appear on a particular HTML page, then the child-links table will be placed at that point where the command occurs. Normally a break tag <BR> is inserted to separate the table of child-links from the surrounding text. The \tableofchildlinks* omits this extra break when it would result in too much space above the table.

For example throughout this section of the manual, all subsections in which several explicit commands have been discussed have their child-links table placed at the top of the page, using \tableofchildlinks*. This helps to quickly find the description of how the commands are used.
change_end 97.1

 

\htmlinfo  


change_begin97.1
Normally an ``About this document...'' page is created at the end of the HTML document, containing technical information about how the document was created, by whom, or any other information contained in the $INFO variable. This information can be made to appear at any other place within the document by specifying \htmlinfo at the desired place in the source. For example, the information may be best suited for the title-page.

The variant \htmlinfo* places the information, but leaves out the standard ``About this document...'' header. Instead the \htmlhead command can be used to place an alternative heading, prior to the \htmlinfo* command. Neither this heading nor the $INFO contents appears in the LATEX typeset version.
change_end 97.1

 

  
\bodytext{<options>}


change_begin96.1g
The text and background colors, and colors for the text of hypertext links can be set on an HTML page by giving appropriate attributes with the <BODY ...> tag. This is particularly easy to do using the \bodytext command, which simply inserts the <code> as the desired list of attributes.


 
Warning: Any previous settings for the <BODY ...> tag are discarded. Furthermore no checking is done to verify whether the given <options> indeed contains a list of attributes and values valid for the <BODY ...> tag.
When using \bodytext you are assumed to know precisely what you are doing!


Other packages contain commands which alter the contents of the <BODY ...> tag; notably the color.perl implementation of LATEX's color package, and the (prototype) frames package, by  Martin Wilck and  Ross Moore . In both these packages the requested information is checked for validity as an attribute within the <BODY ...> tag.
change_end 96.1g
 

  
\htmlbody{<options>}


change_begin97.1
This is similar to the \bodytext command, except that it adds the value of an attribute, or allows an existing value to be changed. Thus it can be used to alter just a single one of the text and background colors, colors for the text of hypertext links or add a background pattern. The <options> are given as key-value pairs; some checking is done to ensure the validity of the attributes whose values are being set.
change_end 97.1
 

  
\htmlbase{<URL>}


change_begin96.1g
This specifies that the given <URL> be included in the <HEAD> section of each HTML page via a tag: <BASE HREF="<URL>".
Such a feature is particularly useful...
change_end 96.1g

  

  
\HTMLset{<which>}{<value>} and \HTMLsetenv{<which>}{<value>}


change_begin97.1
The \HTMLset command provides a mechanism whereby an arbitrary Perl variable can be assigned a value dynamically, during the LATEX2HTML processing. A variable having name `$<which>' is assigned the specified <value>, overwriting any value that may exist already. The \HTMLsetenv is for the same purpose, but it is expanded in order as if it were an environment, rather than a command.


Warning: This is intended for Perl programmers only. Use this command at your own risk!
change_end 97.1



   

\latextohtml  


change_begin97.1
expands to the name LATEX2HTML, of this translator. Commands for parts of names of important LATEX packages are also included with LATEX2HTML: e.g. TEX, LATEX, AMS, XY. (This is to make it easy to refer to these products, in a consistent way within the HTML pages; you may still need LATEX definitions for the typeset version.)
change_end 97.1



next up previous contents index
Next: Active Image Maps Up: No Title Previous: Cross-Referencing Example

Generated using the LaTeX2HTML
11/1/1997