Allow to call get_layout_fun with less parameters by specifying defaults

main
parent 44ce296581
commit 7df29a9acc

@ -759,7 +759,7 @@ def in_to_pt(length):
return 72*length
def get_layout_fun(pagesize, imgsize, border, fit, auto_orient):
def get_layout_fun(pagesize=None, imgsize=None, border=None, fit=None, auto_orient=False):
def fitfun(fit, imgwidth, imgheight, fitwidth, fitheight):
if fitwidth is None and fitheight is None:
raise ValueError("fitwidth and fitheight cannot both be None")

Loading…
Cancel
Save