v0.3
版本发布时间: 2019-11-15 08:23:22
pdfcpu/pdfcpu最新发布版本:v0.8.1(2024-08-31 21:13:37)
Another watermark focused release comes with full support for the Adobe standard/core fontset.
The new pdfcpu fonts
command prints the fontnames of all supported fonts:
Go-> pdfcpu fonts
Courier
Courier-Bold
Courier-BoldOblique
Courier-Oblique
Helvetica
Helvetica-Bold
Helvetica-BoldOblique
Helvetica-Oblique
Symbol
Times-Bold
Times-BoldItalic
Times-Italic
Times-Roman
ZapfDingbats
pkg/testdata/fontsamples
contains single page PDF files - each stamped with the full character set of one of the supported fonts for your reference. The corresponding test for producing these files is located here:
pkg/api/api_test.go: TestCreateFontSamples
All characters regular or special are supported like € or eg. the german äöüÄÖÜß
In order to fully support creating watermarks/stamps containing any character a cli change was necessary:
pdfcpu stamp add [-v(erbose)|vv] [-q(uiet)] [-pages selectedPages] [-upw userpw] [-opw ownerpw] -mode text|image|pdf string|file description inFile [outFile]
pdfcpu stamp remove [-v(erbose)|vv] [-q(uiet)] [-pages selectedPages] [-upw userpw] [-opw ownerpw] inFile [outFile]
pdfcpu stamp update [-v(erbose)|vv] [-q(uiet)] [-pages selectedPages] [-upw userpw] [-opw ownerpw] -mode text|image|pdf string|file description inFile [outFile]
pdfcpu watermark add [-v(erbose)|vv] [-q(uiet)] [-pages selectedPages] [-upw userpw] [-opw ownerpw] -mode text|image|pdf string|file description inFile [outFile]
pdfcpu watermark remove [-v(erbose)|vv] [-q(uiet)] [-pages selectedPages] [-upw userpw] [-opw ownerpw] inFile [outFile]
pdfcpu watermark update [-v(erbose)|vv] [-q(uiet)] [-pages selectedPages] [-upw userpw] [-opw ownerpw] -mode text|image|pdf string|file description inFile [outFile]
The mode
flag is now required to set one of three supported watermark types: text|image|pdf
A corresponding new argument holds a string or an image or pdf file name. As of this release description
is a required configuration string for options only.
Please update your scripts accordingly!
The api was improved for PDF Context manipulation during backend processing. The recommended pattern is:
- Get a pdf.Context:
func ReadContextFile(inFile string) (*pdf.Context, error)
- Manipulate the context
- Write the pdf.Context:
func WriteContextFile(ctx *pdf.Context, outFile string) error
Changelog
1e3294b Update README.md, travis & bump version d1e947c Fix #117 d1472e1 Add cmd: pdfcpu fonts 862d9ee Fix #113 ee90fab Fix #114 c961839 Fix #119 9575f75 Add Dmitry Harnitski as contributor ac888fe Fix Color Lookup for Flat encoded image (#130) dc388b8 Add Mateusz Burniak as contributor 8519366 feat: Introduce function PageCountFile (#123) 6a45354 Add minenok-tutu as contributor 110892a Merge in PR edeb2bd constant export (#121) c97ac72 Fix relaxed Outline dict validation ccc83ac Update README.md 27d554f Fix usage of parms in watermark examples . 8c9e503 Fix examples.
1、 pdfcpu_0.3_checksums.txt 382B
2、 pdfcpu_0.3_darwin_386.tar.gz 1.85MB
3、 pdfcpu_0.3_darwin_amd64.tar.gz 1.95MB
4、 pdfcpu_0.3_linux_386.tar.gz 1.78MB
5、 pdfcpu_0.3_linux_amd64.tar.gz 1.87MB