EPUB Output:Replace non breaking hyphens with ordinary hyphens as the default fonts that come with ADE don't suport them.

This commit is contained in:
Kovid Goyal 2009-05-05 12:12:19 -07:00
parent 654462faba
commit 94ab0efc68
2 changed files with 4 additions and 0 deletions

View File

@ -285,8 +285,10 @@ class EPUBOutput(OutputFormatPlugin):
for elem in root.iterdescendants(): for elem in root.iterdescendants():
if getattr(elem, 'text', False): if getattr(elem, 'text', False):
elem.text = special_chars.sub('', elem.text) elem.text = special_chars.sub('', elem.text)
elem.text = elem.text.replace(u'\u2011', '-')
if getattr(elem, 'tail', False): if getattr(elem, 'tail', False):
elem.tail = special_chars.sub('', elem.tail) elem.tail = special_chars.sub('', elem.tail)
elem.tail = elem.tail.replace(u'\u2011', '-')

2
todo
View File

@ -12,3 +12,5 @@
- Use a process pool for speed or multiple process for stability (20 per process?) - Use a process pool for speed or multiple process for stability (20 per process?)
* Change mobi metadata setter to use author_sort setting from MOBI output plugin instead of mobi.py * Change mobi metadata setter to use author_sort setting from MOBI output plugin instead of mobi.py
* Fix HTML-to-ZIP plugin