[reportlab-users] RenderPM and TTF fonts
    Robin Becker 
    robin at reportlab.com
       
    Thu Oct 11 05:36:44 EDT 2007
    
    
  
Nizam Sayeed wrote:
> Robin,
> 
> I do have the Vera fonts installed. The font registers fine because I can
> use it when rendering PDFs using renderPDF but when I try to use renderPM to
> create a PNG, it gives the error about not being able to find T1 files. As
> you said, renderPM does not support TrueType fonts yet.
> 
> I am currently using a Type 1 font with renderPM. But this wont work because
> I display Unicode characters.From what I know, the Type 1 standard does not
> support Unicode characters. And TrueType is not supported on renderPM. So
> what other option is there?
> 
> Best regards,
> 
> Nizam
> 
........
How did you build _renderPM.pyd? It needs to have freetype support at build time 
  so that it can do TTF as we use the freetype package to get the curves from TTFs.
You can do this check to find out if your renderPM has it enabled.
import _renderPM
_renderPM.ft_get_face
if this complains it means the FT support is not compiled in. If it is compiled 
in then something strange is going on. If it's not compiled in you need to get a 
copy of freetype 2 and set up that library so that the setup.py script for 
renderPM can see it. I'm not an expert at freetype, but I know that the 
technique for determining if it is installed is particularly nasty and I don't 
really understand the differences between the different versions.
-- 
Robin Becker
    
    
More information about the reportlab-users
mailing list