mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
IGN:Tag release
This commit is contained in:
parent
7d7091ccc3
commit
60369e8677
@ -44,7 +44,8 @@ def get_metadata_(src, encoding=None):
|
||||
author = match.group(2).replace(',', ';')
|
||||
|
||||
ent_pat = re.compile(r'&(\S+)?;')
|
||||
title = ent_pat.sub(entity_to_unicode, title)
|
||||
if title:
|
||||
title = ent_pat.sub(entity_to_unicode, title)
|
||||
if author:
|
||||
author = ent_pat.sub(entity_to_unicode, author)
|
||||
mi = MetaInformation(title, [author] if author else None)
|
||||
|
@ -201,7 +201,11 @@ class CSSFlattener(object):
|
||||
tag = barename(node.tag)
|
||||
style = stylizer.style(node)
|
||||
cssdict = style.cssdict()
|
||||
font_size = style['font-size']
|
||||
try:
|
||||
font_size = style['font-size']
|
||||
except:
|
||||
font_size = self.sbase if self.sbase is not None else \
|
||||
self.context.source.fbase
|
||||
if 'align' in node.attrib:
|
||||
cssdict['text-align'] = node.attrib['align']
|
||||
del node.attrib['align']
|
||||
|
File diff suppressed because it is too large
Load Diff
Loading…
x
Reference in New Issue
Block a user