parser.add_argument("-H", "--long_help", action="store_true", help="show examples, explanations, additional usage notes")
args = parser.parse_args()
-
# select pages from input files
def parse_page_range(range_string, pages):
start_page = 0
zoom_horizontal = a4_width / (a4_width - crop_left - crop_right)
zoom_vertical = a4_height / (a4_height - crop_bottom - crop_top)
if (zoom_horizontal > 1 and zoom_vertical < 1) or (zoom_horizontal < 1 and zoom_vertical > 1):
- print("Error: opposing zooms.")
- exit(1)
+ raise ValueError("crops would create opposing zoom directions")
elif zoom_horizontal + zoom_vertical > 2:
zoom = min(zoom_horizontal, zoom_vertical)
else: