python生成一个简单的pdf文件
from reportlab.graphics.shapes import Drawing, String
from reportlab.graphics import renderpdf
d = Drawing(200, 200)
s = String(50, 50, 'victor is a Good man', textAncher='middle')
d.add(s)
renderPDF.drawToFile(d, r'd:\victor.pdf', 'simple pdf')
相关文章