mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-09 03:04:10 -04:00
Sync to pluginize
This commit is contained in:
commit
a418271f35
@ -285,8 +285,10 @@ class EPUBOutput(OutputFormatPlugin):
|
||||
for elem in root.iterdescendants():
|
||||
if getattr(elem, 'text', False):
|
||||
elem.text = special_chars.sub('', elem.text)
|
||||
elem.text = elem.text.replace(u'\u2011', '-')
|
||||
if getattr(elem, 'tail', False):
|
||||
elem.tail = special_chars.sub('', elem.tail)
|
||||
elem.tail = elem.tail.replace(u'\u2011', '-')
|
||||
|
||||
|
||||
|
||||
|
@ -305,6 +305,15 @@ class MobiReader(object):
|
||||
self.log.warning('Markup contains unclosed <p> tags, parsing using',
|
||||
'BeatifulSoup')
|
||||
root = soupparser.fromstring(self.processed_html)
|
||||
if root[0].tag != 'html':
|
||||
self.log.warn('File does not have opening <html> tag')
|
||||
nroot = html.fromstring('<html><head></head><body></body></html>')
|
||||
bod = nroot.find('body')
|
||||
for child in list(root):
|
||||
child.getparent().remove(child)
|
||||
bod.append(child)
|
||||
root = nroot
|
||||
|
||||
self.upshift_markup(root)
|
||||
guides = root.xpath('//guide')
|
||||
guide = guides[0] if guides else None
|
||||
|
@ -218,6 +218,10 @@ If it still wont launch, start a command prompt (press the windows key and R; th
|
||||
|
||||
Post any output you see in a help message on the `Forum <http://www.mobileread.com/forums/forumdisplay.php?f=166>`_.
|
||||
|
||||
My antivirus programs claims |app| is a virus/trojan?
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
Your antivirus program is wrong. |app| is a completely open source product. You can actually browse the source code yourself (or hire someone to do it for you) to verify that it is not a virus. Please report the false identification to whatever company you buy your antivirus software from.
|
||||
|
||||
|
||||
I want some feature added to |app|. What can I do?
|
||||
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
||||
|
Loading…
x
Reference in New Issue
Block a user