[l2h] \verbatim and \endverbatim

Jens Lehmann jens.lehmann at goldmail.de
Fri Jan 2 12:36:50 CET 2004

Ross Moore wrote:
> Hello Jens,
> On Thu, 25 Sep 2003, Jens Lehmann wrote:
>>LaTeX2HTML currently supports the verbatim-environment (\begin{verbatim}
>>... \end{verbatim}), but it doesn't honour the commands \verbatim and
>>\endverbatim. These commands are needed if you want to define your own
>>verbatim-like environments (see the documentation of verbatim for more
> Verbatim-like environments are always tricky, because they do not obey
> the rules/style of normal LaTeX syntax for their content.
> However, a definition such as:
> \newenvironment{myspecialenv}
>  {\textbf{This is mine}
>   \begin{verbatim}
>  }
>  {\end{verbatim}
> }
> should work with LaTeX2HTML, even if it doesn't work with LaTeX
> itself.

It doesn't work for me. The output is not correct and I get the 
following warning:

? brace missing for \newedenvironment

This is probably because the }-brace and the {-brace after 
\begin{verbatim} are not recognized.

A testcase can be found in my Debian bug report for this at the bottom: 

I attach it here additionally.

I need the environment for generating the sourcecode-boxes in this 
document: http://www.xith.org/tutes/GettingStarted/html/simple_header.html

Currently I use a workaround, by  putting

\begin{codeblock} % adds HTML for starting a codeblock
[... code ...]
\end{codeblock} % adds HTML for ending a codeblock

I'm not the only one working on this document (but the maintainer) and 
using only \begin{codeblock} and \end{codeblock} would be more intuitive 
and save some time.

As said before I'm happy to answer your questions, if something is not 


PGP Public Key: http://studenten-dresden.de/public_key.asc
-------------- next part --------------
A non-text attachment was scrubbed...
Name: test5.tex
Type: application/x-tex
Size: 556 bytes
Desc: not available
Url : http://tug.org/pipermail/latex2html/attachments/20040102/7b5d7d0f/test5.tex

More information about the latex2html mailing list