mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
...
This commit is contained in:
parent
8f7d8c1022
commit
611c037357
@ -563,8 +563,8 @@ class HTMLPreProcessor(object):
|
|||||||
html = html.replace(start, '<!--')
|
html = html.replace(start, '<!--')
|
||||||
html = html.replace(stop, '-->')
|
html = html.replace(stop, '-->')
|
||||||
# convert ellipsis to entities to prevent wrapping
|
# convert ellipsis to entities to prevent wrapping
|
||||||
html = re.sub('(?u)(?<=\w)\s?(\.\s?){2}\.', '…', html)
|
html = re.sub(r'(?u)(?<=\w)\s?(\.\s?){2}\.', '…', html)
|
||||||
# convert double dashes to em-dash
|
# convert double dashes to em-dash
|
||||||
html = re.sub('\s--\s', u'\u2014', html)
|
html = re.sub(r'\s--\s', u'\u2014', html)
|
||||||
return substitute_entites(html)
|
return substitute_entites(html)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user