Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is the completely remove the margin or simply add a mask? #51

Open
fuzihaofzh opened this issue Mar 21, 2023 · 4 comments
Open

Is the completely remove the margin or simply add a mask? #51

fuzihaofzh opened this issue Mar 21, 2023 · 4 comments
Labels

Comments

@fuzihaofzh
Copy link

Thanks for the great tool. I just wonder whether it completely removes the margin or simply adds a mask like Preview in Mac?

@abarker
Copy link
Owner

abarker commented Mar 21, 2023

It doesn't actually remove any of the PDF page, it just changes the mediabox and cropbox properties of the PDF. Most PDF viewing software then displays the cropped page rather than the full page. This is how it implements the --restore operation: it just saves the old box values in the artbox and can later restore them

@fuzihaofzh
Copy link
Author

@abarker Thanks for the detailed answer, May I know if it possible to add an option to totally remove the margin. In my case, when I embed the corped pdf into my paper, the margin will resume and show some wiered appearance if I convert the paper into PDF/A-2b format.

@Shohreh
Copy link

Shohreh commented May 12, 2023

To actually remove the data from the file, try "mutool trim", which was introducted recently.

@abarker
Copy link
Owner

abarker commented May 13, 2023

As I noted in your other issue, I'm not sure how mutool is implementing the trim and if it is actually different from simply modifying one or more of the PDF boxes like pdfCropMargins already does.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants