Quote:
Originally Posted by JSWolf
So how would you handle backward compatibility with your ePub3 CSS code?
|
As discussed in a different thread, those pseudo-selectors have been around for a
very long time. All browsers (except your Netscape Navigator 1.0) support them and I don’t think there are any current apps that don’t support them. There might be an ancient reader device that doesn’t meet ePub standards, but in that case the device would just ignore the css it doesn’t understand. It would still display fine, it just wouldn’t include the fancy extras. ie. it would display as a normal sentence without the dropcap.
This is similar to a coder that uses color in their coding… looks great on a modern/compliant reader, but still looks ok on a black and white eink…
I think that is a much better alternative than potentially breaking accessibility laws that may be introduced by using the span technique.
EDIT:
To be clear: This technique with the pseudo-selectors is not an ePub3 thing. Pseudo-selectors are supported under ePub2.
The “fallback” aspect would be using Rbnjrg’s example of setting the font range. That would work for any ePub3 compliant reader/app. If the app doesn’t support ePub3 then it would ignore that css and revert to whatever other css you had set. It wouldn’t be as pretty, but it would be acceptable.
My example of the opening quote/dropcap issue works in both ePub2 or 3.