c.setFillColorRGB(255, 0, 0)
c.setFont('Helvetica', 30)
c.drawString(100, 100, 'Hello World')
c.setStrokeColorRGB(0, 255, 0.3)
c.line(2, 2, 2 * inch, 2 * inch)
c.setFillColorRGB(1, 1, 0)
c.rect(4 * inch, 4 * inch, 2 * inch, 3 * inch, fill=1)
c = canvas.Canvas('hello.pdf')
hello(c)
c.showPage()
c.save()
How to change text/font color in reportlab.pdfgen