[l2h] eps files

Ross Moore ross@ics.mq.edu.au
Fri, 11 Oct 2002 11:45:22 +1000 (EST)

Hi Sam,

> > > image still came out empty. i hope you dont mind, but i am emailing
> > > you the most minimal .tex file and eps file in order that you may
> > > reproduce this error...
> > It is the  [rotate=-90]  option that isn't working.
> > If you leave this out, then it works fine...
> >   ....but rotated sideways, of course.
> brilliant! cheers!

So there is nothing wrong with Ghostscript.
In fact there may be a problem with dvips, calculating
the correct %%BoundingBox for the rotated image,
when it constructs the .ps file.

This is because dvips (using the -E option) only includes
TeX material, such as characters and rules.
It may be that it also now includes the  %%BoundingBox
of included images, but it almost certainly does not
know about the rotation, so gets it wrong.
(I need to explorethis further.)

Now here's a partial fix for this difficulty with rotated images.
Put a frame around the image, using \framebox:


Now dvips will use the locations of the rules for the frame
to deduce a correct BoundingBox.

When I did this, the image worked fine with LaTeX2HTML,
but with one proviso:  too much white-space above.

This is due to a very minor error in  latex2html .

Find the line (towards the end, I think) that says:

&process_commands_inline_in_tex (<<_RAW_ARG_CMDS_);

followed by lists of TeX/LaTeX commands with argument patterns.
This includes:

framebox # [] # [] # {}

Just a few lines above this block is a similar (smaller) block

&process_commands_in_tex (<<_RAW_ARG_CMDS_);

Move the entry for  framebox  from the  &process_commands_inline_in_tex
block to the  &process_commands_in_tex  block.
Do *not* move the line for  fbox .
(\fbox  should remain for framing small pieces of text inline,
 within a paragraph, since alignment of the image with a baseline
 is now important. Then  \framebox  is the correct thing to
 use when there is no need to align with a baseline, as with an
 image in a {figure} environment.)

Now try your document again, with the  \framebox{...} command.
It should work correctly now.

(The above-described patch to  latex2html  will become part
of the next update.)

If you don't like the frame, then consult LaTeX documentation
to find out how to make it white, rather than black.
If this results in a gray background to the image,
then put  \pagecolor{white}  into the document preamble.

If you remind me again, I'll try to find a way to make this work
correctly without using \framebox .

Hope this helps,


> > > > Which version of Perl are you running ?
> > > perl-5.8.0
> > That's much more recent than what I usually use, so I cannot
> > test this problem.
> > More later, when I know a bit more,
> ok, but i think maybe as a workaround a sed script could fix the escape
> characters... i have the same problem with the sendmail man page, but
> these 2 pages are the only ones which give a problem...
> thanks again!
> Sam
> -- 
> There seems no plan because it is all plan.
> -- C.S. Lewis