[l2h] Text Size Problems
Ross Moore
Ross Moore <ross@ics.mq.edu.au>
Sat, 23 Oct 1999 13:37:17 +1000 (EST)
> Greetings,
>
> I have a problem with text size when using a particular LaTeX construct.
> The text gets sequentially smaller after each use. The PostScript output
> looks as expected.
>
> The problem arises when using the \hdr command defined below. Here is an
> example:
>
> \def\sp{}
> %\def\sp{\vspace*{1ex}}
> %\def\sp{\vspace*{2mm}}
> %\def\hdr{\large \bfseries \sffamily \upshape}
> \def\hdr{\large \bfseries}
>
Using font size declarations, rather then well-delimited
environments, is not the LaTeX way of doing it
(though it does work for TeX-based LaTeX).
>
> \large
> \textsf{\textup{\textbf{Full Description Catalog}}} \\
> \small
>
> More information is available in the Full Description Catalog. That
>
> \large
> \textbf{\textup{Full Description Catalog}} \\
> \small
The problem is that HTML needs to know where the *end*
of the data occurs, for each of the \large and \small declarations.
With no braces to help, the programming becomes very complicated;
especially since each blank line creates a \par or <P> in HTML,
and any font-closing </FONT> must occur *before* the <P>,
then open with <FONT ... > again afterwards.
Look at the HTML source being produced.
You should see lots of redundant <DIV> and </DIV> tags,
or nested <BIG> and <SMALL> tags.
> More information is available in the Full Description Catalog. That
>
> {\hdr Full Description Catalog} \\
> \small
You will make LaTeX2HTML's job easier,
and get more compact HTML as a result,
if you redefine the macros to read an argument and place it
using fully-scoped LaTeX commands:
\newcommand{\hdr}[1]{\begin{large}\textbf{\textup{#1}}\end{large}}
then use in the body of your source:
\hdr{Full Description Catalog}
Hope this helps,
Ross Moore