'Extract all font related style information from all stylesheets into a
dict mapping classes to font properties specified by that class. All
the heavy lifting has already been done by the CSS flattening code.'

def find_style_rules(self):

    rules = defaultdict(dict)
    for item in self.oeb.manifest:
        if (not hasattr(item.data, u'cssRules')):
            continue
        for (i, rule) in enumerate(item.data.cssRules):
            if (rule.type != rule.STYLE_RULE):
                continue
            props = {k: v for (k, v) in get_font_properties(rule).iteritems() if v}
            if (not props):
                continue
            for sel in rule.selectorList:
                sel = sel.selectorText
                if (sel and sel.startswith(u'.')):
                    sel = sel.partition(u':')[0]
                    rules[sel[1:]].update(props)
    self.style_rules = dict(rules)
