Skip to main content
Inspiring
May 13, 2024
Answered

Crop PDF to crop marks?

  • May 13, 2024
  • 1 reply
  • 382 views

Is there a way to create an Action/Fixup that crops every page of a PDF in the following way: Everything inside the crop marks are kept, but the crop marks themselves plus everything outside is removed.

 

I found a javascript snippet years ago that achieved this as an Action iirc, but I don't have it anymore. Been searching and trying out different solutions but nothing seems to work.

Correct answer Ruben Solér

I managed to find the snippet, which can be saved as an action:

 

/* Crop to Cropmarks */
for (var i=0; i<this.numPages; i++) {
var ar = this.getPageBox("Trim", i);
this.setPageBoxes("Crop", i, i, ar);
}

1 reply

Ruben SolérAuthorCorrect answer
Inspiring
January 22, 2025

I managed to find the snippet, which can be saved as an action:

 

/* Crop to Cropmarks */
for (var i=0; i<this.numPages; i++) {
var ar = this.getPageBox("Trim", i);
this.setPageBoxes("Crop", i, i, ar);
}