Re: Add ViewerPrefs PrintScaling=none to pdf created by pcl6?

Ken Sharp <[email protected]>
Newsgroups gmane.comp.printing.ghostscript.devel
Message-ID <[email protected]>
At 23:04 09/11/2014 -0500, Edward Mendelson wrote:

>I use a slightly modified pcl6.exe to create PDF output from WordPerfect 
>for DOS, and I wonder if it's possible to "bake in" the setting that tells 
>the viewer to print without scaling, specifically:
>
>[ {Catalog} << /ViewerPreferences << /PrintScaling /None >> >> /PUT
>pdfmark

That's all PostScript, and so (clearly) won't work with the PCL 
interpreter. In point of fact, no pdfmark operator will work with the PCL 
interpreter and there is no defined mechanism for controlling PDF output at 
all from the PCL interpreter. See bug #693177 for example, and more 
generally bug #693058:

http://bugs.ghostscript.com/show_bug.cgi?id=693058


>I see from the source code of pcl6 that you don't support the 
>ViewerPreferences, but I wonder if anyone can suggest a way to modify the 
>code so that that setting could be added to the output.

You'll need to parse a command line option, construct a suitable parameter 
set, and call the put_params device method, that's how the PostScript 
interpreter does this and you will need to do exactly the same to get this 
to work.

Or do as suggested in the bug above, a 2-step process.

If you want to add this youreself then you should look at the 
implementation of pdfmark in the PostScript interpreter (which is done in 
PostScript, see ghostpdl/gs/Resource/Init/gs_pdfwr.ps). You will see from 
there that the PostScript code builds an appropriate dictionary argument 
and then calls .pdfputparams to send the dictionary argument to the device.


                 Ken
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.