View Single Post
Old 12-26-2014, 05:58 PM   #8
murg
No Comment
murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.murg ought to be getting tired of karma fortunes by now.
 
Posts: 3,240
Karma: 23878043
Join Date: Jan 2012
Location: Australia
Device: Kobo: Not just an eReader, it's an adventure!
Quote:
Originally Posted by GeoffR View Post
I don't think there is a universal stylesheet that will work very well, there are just too many different ways of creating epubs for one stylesheet to work on them all.
You can come up with one on your own.

This does involve reformatting the ebooks. Which isn't that bad in Sigil. Usually. Don't you just love ebooks with an id on every paragraph. The goal isn't to reformat the ebooks to look just like the original, but to fit your basic formatting requirements.

Most ebooks (99%+) don't have any real fancy formatting.

The basic elements in a reformat are: paragraphs, chapter headings, section breaks, italic, bold, small, blockquotes.

The reformatting involves taking out most of the css referencing in the html, and replacing it with the simple html tags, which are then defined in the css.

As an example of a difficult thing to reformat, you have to identify and fix all of the section breaks. Since this is usually done with css (doing a large top or bottom margin), you get look through the entire book looking for section breaks (in the rendered text view, so it doesn't take too long). Most books use one or two methods for section breaks, some use a wide variety of techniques.

My css has 140 lines (it grows from time to time), and provides standard headers, body, paragraph (and things like left, right, centre). A bunch indents (from -3.5em to 6 em in 0.5 increments), font sizes (0.5em to 3.0 em, some in 0.1 increments), line heights, margin bottoms (for blank lines).

Then it has elements for invisibility, various types of formatted text (including footnotes which I place inline with the text in a bordered box with small text).

I have a few elements for blockquotes. And to handle sub and super scripts.

Most of the css elements don't get used much, but in the books I've reformatted, the books all look alike, both on the screen and in the source text.

I also add standard cover, title, and end pages.
murg is offline   Reply With Quote