diff --git a/src/calibre/ebooks/epub/__init__.py b/src/calibre/ebooks/epub/__init__.py index d8d4c9a758..442f5260b1 100644 --- a/src/calibre/ebooks/epub/__init__.py +++ b/src/calibre/ebooks/epub/__init__.py @@ -156,7 +156,7 @@ to auto-generate a Table of Contents. help=_('Set the right margin in pts. Default is %default')) layout('base_font_size2', ['--base-font-size'], default=12.0, help=_('The base font size in pts. Default is %defaultpt. Set to 0 to disable rescaling of fonts.')) - layout('remove_paragraph_spacing', ['--remove-paragraph-spacing'], default=True, + layout('remove_paragraph_spacing', ['--remove-paragraph-spacing'], default=False, help=_('Remove spacing between paragraphs. Will not work if the source file forces inter-paragraph spacing.')) layout('preserve_tag_structure', ['--preserve-tag-structure'], default=False, help=_('Preserve the HTML tag structure while splitting large HTML files. This is only neccessary if the HTML files contain CSS that uses sibling selectors. Enabling this greatly slows down processing of large HTML files.')) diff --git a/src/calibre/ebooks/epub/from_feeds.py b/src/calibre/ebooks/epub/from_feeds.py index fd1759712d..6a12353f50 100644 --- a/src/calibre/ebooks/epub/from_feeds.py +++ b/src/calibre/ebooks/epub/from_feeds.py @@ -52,6 +52,7 @@ def convert(opts, recipe_arg, notification=None): print 'Generating epub...' opts.encoding = 'utf-8' + opts.remove_paragraph_spacing = True html2epub(opf, opts, notification=notification) diff --git a/src/calibre/ebooks/html.py b/src/calibre/ebooks/html.py index 634963e775..c853f62171 100644 --- a/src/calibre/ebooks/html.py +++ b/src/calibre/ebooks/html.py @@ -848,7 +848,7 @@ class Processor(Parser): # Workaround for anchor rendering bug in ADE css += '\n\na { color: inherit; text-decoration: inherit; cursor: default; }\na[href] { color: blue; text-decoration: underline; cursor:pointer; }' if self.opts.remove_paragraph_spacing: - css += '\n\np {text-indent: 2em; margin-top:0pt; margin-bottom:0pt; padding:0pt; border:0pt;}' + css += '\n\np {text-indent: 1.5em; margin-top:0pt; margin-bottom:0pt; padding:0pt; border:0pt;}' if self.opts.override_css: css += '\n\n' + self.opts.override_css self.override_css = self.css_parser.parseString(self.preprocess_css(css))