Conversion pipeline: Use correct default value of 'inherit' for font-family and font-size when normalizing the shorthand font property

This commit is contained in:
Kovid Goyal 2012-05-21 03:49:38 +05:30
parent 7a4b6ace52
commit 969ce03d0d

View File

@ -457,7 +457,9 @@ class Stylizer(object):
value = primitives.pop() value = primitives.pop()
for key in composition: for key in composition:
if key not in style: if key not in style:
style[key] = DEFAULTS[key] val = ('inherit' if key in {'font-family', 'font-size'}
else 'normal')
style[key] = val
return style return style
def style(self, element): def style(self, element):