Two bugs with dvipng had previously been reported here
- cropping of right and bottom pixels of images
- crashing on blank images, like \( \ \)
Version 0.3 of dvipng was just released and it seems to fix both
of those bugs. Plus, it uses a configure script to set up its compilation. It can be downloaded from http://prdownloads.sourceforge.net/preview-latex/
When I ran configure, I had to set two shell environment variables,
LDFLAGS and CPPFLAGS so that configure would find my copy of the gd
library, and the library/include file for kpathsea.
This version of dvipng seems to return a different exit code on
completion. As a result, the current version of WeBWorK would then give
pink screens whenever images are made successfully. To compensate, you
can either get a new copy of system/lib/ImageGenerator.pm from WeBWorK
cvs, or make the following change to the file. Near the very end is the
line which looks like the following:
warn "$Global::externalDvipngPath -x$dvipng_res -bgTransparent
-Q$Global::dvipngShrinkFactor -mode $Global::dvipngMode
-D$Global::dvipngDPI $self->{filenamestart}.dvi \>\>$error_log
2\>\>$error_log -- FAILED in ImageGenerator.pm returned $cmdout"
if $cmdout != 256;
Then end of the line should be changed to just
... in ImageGenerator.pm returned $cmdout" if $cmdout;
In other words, the "!= 256" gets deleted.
John
<| Post or View Comments |>
|