googlefonts / pyfontaine

Python tool to check font files for language/character set support
https://github.com/googlefonts/pyfontaine
GNU General Public License v3.0
104 stars 20 forks source link

Add an abbreviation attribute to Charmap classes #26

Closed davelab6 closed 10 years ago

davelab6 commented 10 years ago
pyfontaine --set afk,glat,gviet,al4 font.ttf;

is equivalent to

pyfontaine --set Afrikaans,'Google Latin','Google Vietnamese','Adobe Latin 4' font.ttf;
from fontaine.cmap import library
class Charmap:
    common_name = u'Full Polish Alphabet'
    native_name = u'Pełny Polski Alfabet'
    key = ord(u'Ł')
    abbreviation = 'plk'
    polishAlphabet = u"AĄBCĆDEĘFGHIJKLŁMNŃOÓPRSŚTUWYZŹŻaąbcćdeęfghijklłmnńoóprsśtuwyzźż"
    glyphs = map(ord, polishAlphabet)