From 9b21272e46cc17b22c4792a1879968945a956dfb Mon Sep 17 00:00:00 2001 From: Kovid Goyal Date: Thu, 24 May 2012 10:22:16 +0530 Subject: [PATCH] Fix a regression in 0.8.51 that caused conversion to HTMLZ to not have any CSS --- src/calibre/ebooks/htmlz/oeb2html.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/calibre/ebooks/htmlz/oeb2html.py b/src/calibre/ebooks/htmlz/oeb2html.py index a550b814b9..c6a7276f6c 100644 --- a/src/calibre/ebooks/htmlz/oeb2html.py +++ b/src/calibre/ebooks/htmlz/oeb2html.py @@ -120,13 +120,12 @@ class OEB2HTML(object): el.attrib['id'] = self.get_link_id(page.href, el.attrib['id'])[1:] def get_css(self, oeb_book): - css = u'' + css = b'' for item in oeb_book.manifest: if item.media_type == 'text/css': - css = item.data.cssText - break + css += item.data.cssText + b'\n\n' return css - + def prepare_string_for_html(self, raw): raw = prepare_string_for_xml(raw) raw = raw.replace(u'\u00ad', '­')