def fromXML(self, name, attrs, content, ttFont):
    self.format = safeEval(attrs['format'])
    self.reserved = safeEval(attrs['reserved'])
    self.length = safeEval(attrs['length'])
    self.language = safeEval(attrs['language'])
    self.nGroups = safeEval(attrs['nGroups'])
    if (not hasattr(self, 'cmap')):
        self.cmap = {}
    cmap = self.cmap
    for element in content:
        if (not isinstance(element, tuple)):
            continue
        (name, attrs, content) = element
        if (name != 'map'):
            continue
        cmap[safeEval(attrs['code'])] = attrs['name']
def fromXML(self, name, attrs, content, ttFont):
    self.format = safeEval(attrs['format'])
    self.reserved = safeEval(attrs['reserved'])
    self.length = safeEval(attrs['length'])
    self.language = safeEval(attrs['language'])
    self.nGroups = safeEval(attrs['nGroups'])
    if (not hasattr(self, 'cmap')):
        self.cmap = {}
    cmap = self.cmap
    for element in content:
        if (not isinstance(element, tuple)):
            continue
        (name, attrs, content) = element
        if (name != 'map'):
            continue
        cmap[safeEval(attrs['code'])] = attrs['name']