[reportlab-users] degree sign in PDF for temperature Celsius
Robin Becker
robin at reportlab.com
Mon Aug 6 09:54:47 EDT 2007
dimitri pater wrote:
> Hello,
> I am having trouble displaying a degree sign (used for temperature Celsius)
> in a PDF. It is displayed as a black square. Other 'special characters' like
> e-acute and superscript 2 are displayed properly in the PDF. I use platypus.
>
> ideas anyone? Your help is appreciated.
> thanks,
> Dimitri
.......
which font are you using & how are you encoding the degree sign? When I try this
in my simple way I seem to see a degree sign.
from reportlab.pdfgen.canvas import Canvas
c=Canvas('out.pdf')
c.drawString(72,72,'39\xc2\xb0')
c.save()
of course that is using the default font which is Helvetica (I think).
--
Robin Becker
More information about the reportlab-users
mailing list