Summary: | Error: /configurationerror in --setpagedevice-- | ||
---|---|---|---|
Product: | Ghostscript | Reporter: | serge gubenko <serge_gubenko> |
Component: | PDF Interpreter | Assignee: | Alex Cherepanov <alex> |
Status: | RESOLVED WORKSFORME | ||
Severity: | normal | ||
Priority: | P4 | ||
Version: | 8.64 | ||
Hardware: | PC | ||
OS: | Windows XP | ||
Customer: | Word Size: | --- | |
Attachments: |
file which had an error
gs_setpd.ps |
Description
serge gubenko
2009-04-03 08:48:19 UTC
Created attachment 4892 [details]
file which had an error
This file was opened successfully with Adobe Reader I cannot reproduce this. Please provide more information about your system and your copy of Ghostscript. - do you have 32 or 64 bit system ? - have you installed a binary distribution or compiled from sources ? - can you run the sample file on other systems ? - I have 32bit WinXP. - I've installed the binary distribution for gs 8.64. - Can check it on 32bit Windows Server 2003 if needed. Created attachment 4893 [details]
gs_setpd.ps
Sorry, I found the problem, I have custom gs_setpd.ps to restrict the page size to 1728 pixels. Is this possible to configure gs to scale the image if it's bigger then given size? Ghostscript follows the PLRM-3rd edition as to how PageSize matching is performed, including choosing the media from the InputAttributes dictionary according to a fit withing +/- 5 points possibly with rotation to fit. If no page size is close enough, then the 'Policies' dict of the page device come into play. A PageSize policy value of 3 scales down pages that are too large for the largest PageSize and centers smaller pages on the closest larger PageSize. The syntax for this in a setpagedevice dictionary is: << /Policies << /PageSize 3 >> >> setpagedevice I hope this helps. The following prefix removes all predefined input attributes and sets a single variable media size from the modified gs_setpd.ps . Under policy 3, this makes media matching algorithm to scale down the input page size to the media size. Please note that all media attributes are replaced; modified gs_setpd.ps is not needed. << currentpagedevice /InputAttributes get 0 1 2 index length 1 sub {1 index exch undef } for /InputAttributes exch dup 0 <</PageSize [0 0 612 1728]>> put /Policies << /PageSize 3 >> >> setpagedevice Run the prefix before your file as: gswin32c prefix.ps foo.pdf In any case, this is not a bug in Ghostscript. Thank you very much for your help, I apologize for inconvenience, the issue was in my settings not in gs itself. |