Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Python: Printing Html in PDF using Reportlab Canvas

For one of my python project I am using reportlab's canvas feature to generate pdf document.

Can anyone please help me to print small subset of html (p, strong, ul, ol, li, img, alignments) on reportlab canvas?

Thanks in advance...

like image 703
Software Enthusiastic Avatar asked Jul 20 '26 11:07

Software Enthusiastic


1 Answers

If this is what you are tying to do you should look at using Platypus with ReportLab, a built in set of classes in ReportLab for building documents out of objects representing page elements. Or, if you want really simple, xhtml2pdf would probably be better.

like image 115
G Gordon Worley III Avatar answered Jul 22 '26 23:07

G Gordon Worley III



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!