Resize A4 PDF to SRA4 and center content

前端 未结 1 1293
你的背包
你的背包 2021-01-15 05:29

I\'d like to be able to resize an A4 PDF to the slightly bigger SRA4 format, used by printing professionals. The content shouldn\'t be resized, but only centered. In other w

相关标签:
1条回答
  • 2021-01-15 06:02

    I found a solution here, by using -c "<> setpagedevice", like so:

    gs -dPDFSETTINGS=/default -dBATCH -dNOPAUSE -q -sDEVICE=pdfwrite 
    -sOutputFile=out.pdf -dDEVICEWIDTHPOINTS=637 -dDEVICEHEIGHTPOINTS=907 
    -dFIXEDMEDIA -c "<</PageOffset [21 32]>> setpagedevice" -f in.pdf
    

    Content is perfectly centered in the SRA4 document.

    0 讨论(0)
提交回复
热议问题