Replies: 1 comment
-
No, currently there is not. Do not forget to multiply the result by for page in doc:
val = doc.xref_get_key(page.xref, "TrimBox")
if val[0] != "null":
doc.xref_set_key(page.xref, "CropBox", val[1]) This also tackles orchid cases, where the trimbox value is not given as a direct array, but indirectly (as an xref). |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have some pdf files created by Adobe InDesign (with bleed setting). And I want to crop only the "TrimBox" range of every page to image. Is it possible to get the coordinate?
I can get the info with code:
Is there more simple way to do this? Like:
trimbox.pdf
Beta Was this translation helpful? Give feedback.
All reactions