|
From: Ethan M. <merritt@u.washington.edu> - 2007-10-09 18:59:27
|
On Tuesday 09 October 2007 01:25, Ludovic Court=E8s wrote: > The problem is not with PDF, but rather with the interpretation of the > `pdfmark' operator by "distiller" applications such as ps2pdf I agree. Therefore I consider it a bug in ps2pdf. > It turns out that both LaTeX+hyperref and Lout (which is what I use) put > their Info dictionary marker at the beginning of the PS document; thus, > that Info dictionary gets overridden by the one present in the > included GNUplot-generated EPS files. QED. Yes, that was the original failure mode reported in an earlier bug report. > Furthermore, I question the usefulness of `pdfmark' in EPS files. EPS > files are meant to be embedded, as the name implies, and probably not > converted to PDF. Thus, `pdfmark' instances within EPS appear to be of > little use; `pdfmark' in *PS* files, OTOH, are admittedly useful, and my > patch preserves them. I beg to differ. An equally common path is to convert the individual figures from *.eps to *.pdf and then assemble the document using pdflatex. The metadata in the individual *.eps pdfmark sections are then attached to the individual figures, and can be used to navigate the resulting composite pdf document. At least, that's the intent. If it's broken, let's fix it. You may ask "in that case, why use gnuplot to create eps figures rather than pdf figures"? Until recently, creating pdf figures directly required building gnuplot from source and linking against the proprietary PDFlib library. So this path was not generally available. In the CVS version of gnuplot there is now an experimental cairo-based pdf terminal that may obviate this problem. But until that matures and perhaps a corresponding "pdflatex" terminal is written, I think it is disirable to continue to support the inclusion of pdf metadata in *.eps output. =20 If there is a better mechanism to do so, great. But I'd rather fix the problem by improving the support rather than by removing it altogether. The pdfmark Reference you point to below gives a lot of suggestions how to create more sophisticated tags; perhaps someone will be inspired to modify post.trm to emit more sophisticated pdfmark sections. =46inally, I note that the pdfmarkReference also provides a sample code chunk to disable pdfmark interpretation by PostScript interpreters. Now that gnuplot allows local customization of the PostScript prologue files, perhaps the most straightforward immediate solution is for you=20 to add the code fragment to your local prologue file? That has the nice feature that it applies to all existing installations of 4.2; it doesn't require rebuilding gnuplot.=20 > http://partners.adobe.com/public/developer/en/acrobat/sdk/pdf/pdf_creatio= n_apis_and_specs/pdfmarkReference.pdf =2D-=20 Ethan A Merritt |