Linux PDF版本转换器


22

我想使用命令行实用程序将PDF从1.5版转换为1.4版。

有空吗?

Answers:


28

ubuntu论坛中找到了这个:

 # gs -sDEVICE=pdfwrite -dCompatibilityLevel=<VERSION> -dPDFSETTINGS=/screen -dNOPAUSE -dQUIET -dBATCH -sOutputFile=output.pdf input.pdf

刚刚测试了一下,它工作正常,我现在将发布一些输出。

[14:08:41]lee@barlow:~/superuser # pdfinfo org_1-4.pdf 
Title:          CV 2009
Producer:       Prince 7.0 alpha 16 (www.princexml.com)
Tagged:         no
Pages:          3
Encrypted:      no
Page size:      595 x 842 pts (A4)
File size:      51793 bytes
Optimized:      no
PDF version:    1.4
[14:08:59]lee@barlow:~/superuser # gs -sDEVICE=pdfwrite -dCompatibilityLevel=1.5 -dPDFSETTINGS=/screen -dNOPAUSE -dQUIET -dBATCH -sOutputFile=out_1.5.pdf org_1-4.pdf
[14:09:35]lee@barlow:~/superuser # pdfinfo out_1.5.pdf 
Producer:       GPL Ghostscript 8.64
CreationDate:   Wed Aug 19 14:09:34 2009
ModDate:        Wed Aug 19 14:09:34 2009
Tagged:         no
Pages:          3
Encrypted:      no
Page size:      595 x 842 pts (A4)
File size:      60658 bytes
Optimized:      no
PDF version:    1.5

1
只是注意到示例是向后的。1.4-> 1.5而不是1.5-> 1.4。嗯,谢谢你的投票:)
lyarwood

没问题 我解决了:P
汤姆(Tom),2009年
By using our site, you acknowledge that you have read and understand our Cookie Policy and Privacy Policy.
Licensed under cc by-sa 3.0 with attribution required.