Warning: session_start(): Session cannot be started after headers have already been sent in /home/tvrreohg/public_html/manga.php on line 13
3 2øªjã@sDdZddlmZddlmZmZdd„Zdd„ZGdd „d eƒZd S) z0ttLib.macUtils.py -- Various Mac-specific stuff.é)ÚBytesIO)ÚResourceReaderÚ ResourceErrorc Cs8yt|ƒ}|jdƒ}|jƒ|Stk r2gSXdS)z;Determine whether a file has a 'sfnt' resource fork or not.ÚsfntN)rZ getIndicesÚcloser)ÚpathÚreaderÚindices©r ú=/tmp/pip-build-_d5lkt3n/fonttools/fontTools/ttLib/macUtils.pyÚgetSFNTResIndicess r cCsdddlm}g}t|ƒ}|s.|j|j|ƒƒn2x|D]}|j|j||ƒƒq4W|s`|jd|ƒ‚|S)züGiven a pathname, return a list of TTFont objects. In the case of a flat TTF/OTF file, the list will contain just one font object; but in the case of a Mac font suitcase it will contain as many font objects as there are sfnt resources in the file. r)ÚttLibzno fonts found in file '%s')Ú fontToolsr r ÚappendZTTFontÚ TTLibError)rr ZfontsZsfntsÚindexr r r Ú openTTFontss  rcs eZdZdZ‡fdd„Z‡ZS)ÚSFNTResourceReaderz3Simple read-only file wrapper for 'sfnt' resources.csxddlm}t|ƒ}t|tƒr,|jd|ƒ}n |jd|ƒ}|dkrN|jd|ƒ‚|jƒ||_ t t |ƒj |j ƒ||_dS)Nr)r rzsfnt resource not found: %s)rr rÚ isinstanceÚstrZgetNamedResourceZgetIndResourcerrÚrsrcÚsuperrÚ__init__ÚdataÚname)ÚselfrZres_name_or_indexr rr)Ú __class__r r r(s   zSFNTResourceReader.__init__)Ú__name__Ú __module__Ú __qualname__Ú__doc__rÚ __classcell__r r )rr r$srN) r ÚiorZfontTools.misc.macResrrr rrr r r r Ús