[reportlab-users] Disable XML parsing in Paragraph(..)

Andy Robinson reportlab-users@reportlab.com
Fri, 9 Jul 2004 00:19:44 +0100

> I guess I should quote < and & in stuff I send into paragraphs?

Yes, that's the easy way.  There is a library function to do it

>>> import xml.sax.saxutils
>>> xml.sax.saxutils.escape("Medicine & Dentistry")
'Medicine &amp; Dentistry'

> How about stuff I'm putting on with canv.drawString?

No, that is not treated as XML. The ONLY places where
input is treated as XML are Paragraphs and Preformatted
text objects.  

- Andy