pdfcpu

Logo

A PDF processor written in Go.

View the Project on GitHub pdfcpu/pdfcpu


Changelog

N-down


Usage

pdfcpu ndown [-p(ages) selectedPages] -- [description] n inFile outDir [outFileName]


Flags

name description required
p(ages) selected pages no


Common Flags

name description values
v(erbose) turn on logging  
vv verbose logging  
q(uiet) quiet mode  
-o(ffline) disable http traffic  
c(onf) config dir $path, disable
opw owner password  
upw user password  
u(nit) display unit po(ints),in(ches),cm,mm


Arguments

name description required
description configuration string no
n the N-down value yes
inFile PDF input file yes
outDir output directory yes
outFileName PDF output file name no


N-down Value

The following table lists all supported values for n and the resulting poster tile layout with respect to the orientation of the chosen output paper size.

value portrait landscape Example
2 1x2 2x1 A1 -> 2 x A2
3 1x3 3x1  
4 2x2 2x2 A1 -> 4 x A3
8 2x4 4x2 A1 -> 8 x A4
9 3x3 3x3  
12 3x4 4x3  
16 4x4 4x4 A1 -> 16 x A5


Description

A configuration string to specify the details of the grid layout.

parameter description values
margin margin / glue area in display units >= 0.0
bgcolor margin / glue area color value color
border draw content region border along set margin on/off, true/false, t/f


Examples

The page format is A2, the printer supports A3.
Quick cut a page into 2 equally sized pages.
Results in a PDF containing 3 pages for each processed page:


$ pdfcpu ndown 2 test.pdf .
cut test.pdf into ./ ...
writing test_page_1.pdf




The page format is A2, the printer supports A4.
Quick cut page into 4 equally (A4) sized pages.
Results in a PDF containing 5 pages for each processed page:

$ pdfcpu ndown 4 test.pdf .
cut test.pdf into ./ ...
writing test_page_1.pdf




The page format is A2, the printer supports A4.
Quick cut page into 4 equally (A4) sized pages and provide a dark gray glue area of 1 cm.
Results in a PDF containing 5 pages for each processed page:

$ pdfcpu ndown -u cm -- "margin:1, bgcol:DarkGray, border:on" 4 test.pdf .
cut test.pdf into ./ ...
writing test_page_1.pdf