def __init__(self, filename, **kw):
m = 2*cm
cw, ch = (PAGESIZE[0]-2*m)/2., (PAGESIZE[1]-2*m)
f1 = Frame(m, m+0.5*cm, cw-0.75*cm, ch-1*cm, id='F1',
leftPadding=0, topPadding=0, rightPadding=0, bottomPadding=0,
showBoundary=True
)
f2 = Frame(cw+2.7*cm, m+0.5*cm, cw-0.75*cm, ch-1*cm, id='F2',
leftPadding=0, topPadding=0, rightPadding=0, bottomPadding=0,
showBoundary=True
)
apply(BaseDocTemplate.__init__, (self, filename), kw)
template = PageTemplate('template', [f1, f2])
self.addPageTemplates(template)
评论列表
文章目录