Quote:
Originally Posted by JSWolf
You have to be careful. If ADE 2.0.1 or 3.x thinks your code is a mistake, the entire CSS will be ignored.
What would happen if you had first-letter and a span for a program that supports both? This is a good reason to forgo drop caps if you need ePub2 compatibility.
|
Since I'm back working on
Under the Lilacs (on to scanning images and processing, almost done with the illustrated titlepage), and since the 1910 hardcover has, you guessed it, drop caps, I was delighted to see that initial-letter is getting some support.
So, for the moment at least, I've added it:
Code:
p.chapter-lead::first-letter {
initial-letter: 2;
-webkit-initial-letter: 2;
}
Here's a few images so you can see what it looks like in Sigil (which is similar to what happens in supported apps) and what it looks like in Adobe Digital Editions, v2.0.1. Same file, same code, same computer.
Now, you do have to play about with it. For instance, if you add any padding, you have to consider that if a device honors first-letter but NOT initial-letter, you could get an odd look if you go crazy with too much. A tiny dab might be OK. I've been playing with adding a
trace for the letter "I", because it tends to look a bit cramped otherwise.
It's possible it might not play well with every font too, I tried it with Open Dyslexic and placement of the drop cap was odd. So a risk, given one never knows what fonts people will decide to read with. I've seen folks post some doozies!
And, with a phone in landscape orientation, you run the risk that if only the first line of the chapter fits on the screen, your drop cap will show, but its bottom half on the second line will be truncated....
I tossed the epub into the Kobo iOS app and also BookFusion iOS, and not only is initial-letter honored, but also hanging-punctuation! YAY! I tossed in a picture of the hanging-punctuation property working in the Kobo app on my iPad!
Fun times if you make backward compatible epub3! You can't eat cake ALL the time, but
sometimes is nice!