[SOLVED] Paragraph spacing from HTML to ePUB
I am having problems forcing Calibre not to overwrite my formatting.
Let's say I format a HTML file inside MS Word. I am aware that MS Word includes lots and lots of garbage in the code, but I know many tricks in Word that I am unable to replicate in serious HTML editors.
Let's say I define a heading as having no indent and the main text body as having indent in most cases, but not always. The main text body has no paragraph spacing in the HTML code, either.
I enter this file into Calibre and convert it into ePUB. With the "Remove spacing between paragraphs" option disabled, Calibre adds paragraph spacing even though the HTML formatting does not mention any such thing. OK. I enable "Remove spacing between paragraphs" and I am forced to enter a value for "Indent size" (0 means no indentation, rather than "do not touch the indent"). The resulting ePUB has no paragraph spacing, but the same indent size for every paragraph.
For the record, I am just mentioning ePUB here because it is easier to see the resulting code, but my intention is to convert to MOBI. The same problems happen with ePUB and MOBI, anyway. The Amazon kindlegen utility respects the HTML code, but I prefer Calibre because it adds the TOC info and the cover for me.
How do I force Calibre to honour the HTML format which specifies spacing and indent for every paragraph?
Attachments (within the ZIP):
adventures.htm > Source HTML file with Word 2010 garbage HTML code
adventures_checked.epub > Output ePUB with the "Remove spacing between paragraphs" disabled and "0 pt" as indent size
adventures_unchecked.epub > Output ePUB with the "Remove spacing between paragraphs" disabled
Last edited by lordvetinari2; 11-22-2010 at 09:56 AM.
Reason: Solved!
|