View Single Post
Old 05-15-2010, 08:56 AM   #14
jackie_w
Grand Sorcerer
jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.jackie_w ought to be getting tired of karma fortunes by now.
 
Posts: 6,212
Karma: 16534894
Join Date: Sep 2009
Location: UK
Device: Kobo: KA1, ClaraHD, Forma, Libra2, Clara2E. PocketBook: TouchHD3
Hi Amalthia,

I only have MSWord (Office XP version, so quite old) so I'm afraid I can't try another word-processer.

I have never had any problem with the <h2> etc tags not appearing in the output HTML. However, I create my HTML direct from Word using the Web-Filtered save-as option to get rid of much of the MS excess baggage.

Contrary to popular belief you can get beautiful clean HTML out of Word with a bit -- OK, a LOT -- of effort.

I offer the following as info for yourself, but probably not suitable for a beginner's guide. My many hours of toil and strife resulted in the following:-
  1. Created my own MSWord ebook template containing
    - a limited number of styles set up to my taste
    - a large number of macros which I can use as required

  2. Created my own standard ebook CSS file which closely matches the ebook template styles - it doesn't have to be exact.

  3. When I want to clean up a file (RTF, HTML, DOC, TXT), I import the source into my ebook template and apply the styles strictly using the macros. Then I save as Web-Filtered HTML.

  4. Finally, I edit the HTML as a text file (using a macro) and:-
    - remove everything between (and including) the <style>...</style> tags
    - replace with a single line linking to a copy of my standard ebook CSS file
    Code:
    <link rel="stylesheet" type="text/css" href="ebook.css" />

Result - simple, clean, readable HTML to import to Calibre.

In short, I use Word merely to get the HTML tagged correctly. All the styling is contained in the CSS file, which can be tweaked for an individual book if I really want to.

Most of the effort went into steps 1 and 2 which is now complete - until I want to add new features.

Anyway, enough from me. I could discuss this stuff for hours but I don't suppose many people would be interested.

P.S. By the way, I use Notepad++ for text editing HTML files because of its automatic colour-coding. It makes it so much easier to find matching start/end tags.
jackie_w is offline   Reply With Quote