View Single Post
Old 10-09-2020, 10:02 PM   #57
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 681
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by FDPuthuff View Post
I am following this guy's method to start. I
(Guido Henkel's "Zen of eBook Formatting")

I read that and it's a good introduction to basic CSS. However one of his precepts I think is quite ill-advised:
Quote:
Originally Posted by Guido Henkel
there is one group of HTML tags in particular that I think I should single out at this point. I usually stay away from using <h1> tags and its brethren <h2>, <h3>, <h4>, <h5> and <h6>. These are tags that are usually used to create headlines. They are often predefined in web browsers and eBook readers and as a result they are strange bedfellows. Despite the use of style sheets, I have found that their behavior can be quite unpredictable, depending on the device or browser you are using. Since we can recreate the desired behavior of these tags easily through the use of specially styled paragraphs, I usually prefer going that route instead.
You can get the same appearance, but "hn" tags gives the book structure. And tools like the TOC generator can use them. Dumb reader apps that can't parse styles (or if you have an error in your CSS) can show you something intelligible instead of a page of plain text.

One of the first things I do is convert chapter heads to h tags and then style the h tags. Simpler and more readable code and easier to manage.

Invest some time in learning regular expressions. Very useful in Sigil to clean up cruft from Word or other sources. Get the Tag Mechanic Sigil plugin.

Also, look at Calibre. It has advanced much since Guido wrote his book. Its editor has some quite powerful and useful features.

Quote:
Originally Posted by FDPuthuff View Post
So, when you have a 'perfectly' styled Word doc and you send it through Calibre, or your app of choice, you get your EPUB file. In my tests, I see a lot of HTML that I am not as familiar with. As long as it looks like I expect in an eReader, or previewer, am I good as far as the code? Will the EPUD file work on most eReaders young and old? Or are there 'things' I need to change the tags on because it just makes things unreadable on older devices and or phones?
Get the ePubCheck Sigil plugin.


Quote:
Originally Posted by exaltedwombat View Post
If you put messy source into some converters, you CAN get ridiculous EPUB code where every syllable is given a separate, verbose in-line style.
The RemoveInLineStyles Plugin converts all those to CSS styles.
You might get 100 similar styles, but easier to then merge and simplify them.
AlanHK is offline   Reply With Quote