Last active
December 9, 2017 08:51
-
-
Save ivan/0356a4d7a39996153102990785d5a4c2 to your computer and use it in GitHub Desktop.
Add a lot of margin to the left and right side of a PDF, because PDF viewers on iOS/iPad won't let you stay zoomed out
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
set -eu | |
# Add a lot of margin to the left and right side of a PDF, because PDF | |
# viewers on iOS won't let you stay zoomed out & read with smaller fonts. | |
# | |
# Requirements: apt-get install texlive-extra-utils | |
# | |
# Note: unfortunately, may sometimes reveal printing instructions | |
# outside of the existing margin. | |
input=$1 | |
output=$(basename -- "$input" .pdf)_PADDED.pdf | |
pdfcrop --margin '200 10 200 10' -- "$input" "$output" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Linked from https://apple.stackexchange.com/questions/301051/is-there-an-ipad-pdf-viewer-that-can-stay-zoomed-out