[l2h] \item in \input file

Ross Moore Ross Moore <ross@ics.mq.edu.au>
Sat, 11 Sep 1999 14:32:46 +1000 (EST)


> I found a regression in version 99.2alpha9 after replacing my previous
> version, 98.2beta8.
> 
> The text " <tex2html_file>#./former.tex# " appears in the HTML when
> running latex2html on the following reduced case:
> 
>   simple.tex
>   ----------
>       \documentclass{report}
>       \usepackage{html}
>       
>       \begin{document}
>       
>       \begin{description}
>       \input{former}
>       \end{description}
>       
>       \end{document}
>             
>   former.tex
>   ----------
>       \item Steve
> 
> The unwanted HTML seems to only appear when "\item Steve" is on the
> first line of former.tex.  Even inserting a blank line above "\item
> Steve" causes the problem to disappear.

Oops, just a tiny slip-up.
Here is the complete fix:

In the file  latex2html.pin  make the following edit:


# remove file-markers; special packages may redefine &replace_file_marks
sub remove_file_marks {
    s/($file_mark|$endfile_mark)\#.*\#\n?//gm; }
                                        ^-------- insert this '?' character
sub replace_file_marks { &remove_file_marks }

 
In your example the \n was being gobbled for some (probably good) reason,
so this pattern was not matching, to do its clean-up.


> This problem shows up in many different files I have, causing the html
> to look really bad in a browser.  Is there a way I can patch this?

Yep; a 1-character edit, then do   make install .

 
> I really appreciate all the help I have received in the past.  Thank
> you so much.

You're welcome.

	Ross Moore