首页 > 解决方案 > 将 PostScript 纸张尺寸转换为 a4 并移动页面图像

问题描述

我必须将 PostScript 文件转换为 a4 大小并移动页面图像,我对 GS 还没有经验,但是在阅读了一些指南和一些 Q/A 答案之后,到目前为止,这就是我想出并尝试执行的(在Unix):

/apps/gs/ghostpdl-9.52/bin/gs -dSAFER -dBATCH -dNOPAUSE -q -sDEVICE=ps2write -sOutputFile=/data/test/out_a4.ps -sPAPERSIZE=a4 -dFIXEDMEDIA -c "<</PageOffset [- 72 0]>> setpagedevice" -f /data/test/INPUTFILE.ps

but what I am getting in the terminal are several returns of maybe loops saying: %%HiResBoundingBox: 0.000000 15.444000 488.883993 782.009976 %%BoundingBox: 0 15 489 783 %%HiResBoundingBox: 0.000000 15.444000 488.883993 782.009976 %%BoundingBox: 0 15 489 783 %% HiResBoundingBox:0.000000 15.444000 488.879985 782.009976

并且没有创建输出文件。

希望有人能帮忙,谢谢

编辑:当在 Windows 中运行相同的命令时,它会给出输出 "<C:\Program Files\gs\gs9.14\bin\gswin64c.exe>" -dSAFER -dBATCH -dNOPAUSE -q -sDEVICE=ps2write -sOutputFile =C:\test\OUTPUTFILES\out_a4.ps -sPAPERSIZE=a4 -dFIXEDMEDIA -c "<</PageOffset [-72 0]>> setpagedevice" -f C:\test\INPUTFILES\INPUTFILE.ps

所以我可能需要纠正一些事情才能使其在 Linux 环境中工作?...

标签: ghostscriptpostscript

解决方案


推荐阅读