关于python reportlab 库的学习 二 SimpleDocTemplate
在使用SimpleDocTemplate之前,我们先看一下reportlab中,我们会在pdf中用到的一下类:
styles字体样式字典:具体使用格式如下
from reportlab.lib.styles import getSampleStyleSheet
styles=getSampleStyleSheet()
stylesheet.add(ParagraphStyle(name='Title',
fontName=_baseFontName,
fontSize=10,
leading=12)
)
from reportlab.platypus import Paragraph,Spacer,Image,Table