[reportlab-users] Verdana and TTF error

Andy Robinson reportlab-users@reportlab.com
Tue, 4 May 2004 17:32:29 +0100

> as was suggested earlier in the list I installed the VERDANA.TTF file on 
> my Linux box. The file is found, but when I try to register the font 
> like this
>      pdfmetrics.registerFont(TTFont('Verdana', 'VERDANA.TTF'))
> I get an error message (please find it below).
> What is wrong with the font?

OK, I think this was a bug in our last version.  Somebody
had already put in some declarations about common font names
(including Verdana) to say which files to use for bold, italic 
etc, which prevented the name verdana from being registered.
Are you using 1.19?  If so, you should get a daily snapshot
or CVS copy since we removed it two months ago.  Or, if you feel brave, 
go into  reportlab/pdfbase/_fontdata.py

and look for some code like this:

standardFontAttributes = {
    #family, bold, italic defined for basic ones




Delete all the extra fonts ('verdana') except the above 
ones :-)

- Andy