How to retrieve contents of a NameRecord in Fonttools?

This will get me the list of name table entries:

        ttfont = TTFont(filename)
        print str(ttfont['name'].names) 

But what if I want to retrieve the associated record, like retrieve the copyright as a string?

I was hoping this would work:
        ttfont = TTFont(filename)
        print str(ttfont['name'].getName(0,1,0))  

but that just returns:

<NameRecord NameID=0; PlatformID=1; LanguageID=0>


thanks!

Comments

Sign In or Register to comment.