Quote:
Originally Posted by pedronac
Hello,
I need to crop several rectangles from a page.
I try to use the command line (so I do not need to do all the setup over GUI)...
|
This can be done w/
k2pdfopt as well. See the
-mode and
-cbox options in the
command-line usage. Something like so:
Code:
k2pdfopt -mode crop -cbox <cropdims1> -cbox <cropdims2> [...] sourcefile.pdf
example:
Code:
k2pdfopt -mode crop -cbox 1in,1in,2in,3in -cbox 5in,4in,2.5in,3.5in myfile.pdf
This would take a 2x3 inch box, starting 1 inch from the left and 1 inch from the top, on each source page, and create a destination page out of it, followed by a 2.5x3.5 inch box, starting 5 inches from the left and 4 inches from the top of each source page. You can also specify a source page range for each crop box, e.g.
-cbox2-10 <cropdims> would apply those crop dimensions to only source pages 2 through 10.