mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Handle nbsp in all its incarnations.
This commit is contained in:
parent
59a1af6050
commit
d4b540b8cf
@ -70,7 +70,7 @@ class HTMLConverter(object):
|
|||||||
(re.compile(r'<a.*?>(.*?)</a\s*>', re.DOTALL|re.IGNORECASE),
|
(re.compile(r'<a.*?>(.*?)</a\s*>', re.DOTALL|re.IGNORECASE),
|
||||||
lambda match: re.compile(r'<\s*?p.*?>', re.IGNORECASE).sub('', match.group())),
|
lambda match: re.compile(r'<\s*?p.*?>', re.IGNORECASE).sub('', match.group())),
|
||||||
# Workaround bug in BeautifulSoup handling
|
# Workaround bug in BeautifulSoup handling
|
||||||
(re.compile(r' ', re.IGNORECASE), lambda match : u'\uffff')
|
(re.compile(u' | | |\xa0', re.IGNORECASE), lambda match : u'\uffff')
|
||||||
]
|
]
|
||||||
# Fix Baen markup
|
# Fix Baen markup
|
||||||
BAEN = [
|
BAEN = [
|
||||||
|
Loading…
x
Reference in New Issue
Block a user