Re: Using Symbola or equivalent Unicode6 font with Reportlab

Robin Becker <[email protected]>
Newsgroups gmane.comp.python.reportlab.user
Message-ID <[email protected]>
On 21/02/2014 17:12, Mathieu Comandon wrote:
...........
> I tried running your code snippet using the ms-mincho fonts (but running on
> Linux) and I got the following error:
>
>      raise RenderPMError("Can't setFont(%s) missing the T1
> files?\nOriginally %s: %s" % (fontName,s1,s2))
>      reportlab.graphics.renderPM.RenderPMError: Can't setFont(ms-mincho)
> missing the T1 files?
>      Originally <type 'exceptions.AttributeError'>: TTEncoding instance has
> no attribute 'vector'
>
> I will try debugging this and using other fonts on monday. Also, we are
> using Platypus flowables to generate the contents, I hope it doesn't affect
> the font rendering, I'll try converting your snippet using Platypus.
>
you just need to download some fonts into the reportlab/fonts folder you can get 
them here

http://www.reportlab.com/ftp/pfbfer-20070710.zip

alternatively try removing 'png' from the list of outputs ie formats=['pdf'] in 
the save command. I think we need those T1 font pfbs for renderPM output, but 
not for PDF.
-- 
Robin Becker
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.