From: Ralf H. <hem...@ri...> - 2004-08-30 07:42:32
|
Hello, Otfried Cheong wrote: > Jay Belanger writes: > > The correspoding references in the html file would have to match; how > > hard would it be to arrange that? Would that be tricky at all? > > Are there any advantages to specifying the image file name? > > (Obviously, I don't know the answer to any of these.) > > When I originally added image generation to Hyperlatex, I wanted to > automatically assign a file name, but I was inable to come up with a > reliable way to synchronize the filename between HTML and Latex (think > about images that are not shown in one version -- simply counting > get's completely out of step them). Hmmm, as far as I understand, \begin{gif}{filename}..\end{gif} is for things that are not easily typeset in HTML, for example, some mathematical formulae. If \makegifs or \makeimages (in version 2.7) is defined, images will be generated via latex otherwise the gif or image environment is \def\@@@@image{\tex} \def\endimage{} So it simply switches to TeX and does nothing. To me that means that the generated images are solely for the HTML version, so why does counting not work? If \makeimages is defined the corresponding images appear (by some magic) on the first few pages of the dvi file and are extracted by dvips -p To syncronise, it would be only necessary to step a counter via elisp for each \begin{image}. I know that there still could be a problem when one has something like \begin{ifhtml}\begin{image}..\end{image}\end{ifhtml} One could repair this by saying that if \makeimages is defined one defines in hyperlatex.sty \newenvironment{ifhtml}{}{} \newenvironment{iftex}{\comment}{\endcomment} where the 'comment' stuff is taken from \usepackage{verbatim}. One should remember that for the html generation, the generated dvi file is for creating the images and thus an auxiliary file. Do I see something wrong here? Ralf |