View Single Post
Old 01-18-2013, 08:01 PM   #19
dgatwood
Curmudgeon
dgatwood ought to be getting tired of karma fortunes by now.dgatwood ought to be getting tired of karma fortunes by now.dgatwood ought to be getting tired of karma fortunes by now.dgatwood ought to be getting tired of karma fortunes by now.dgatwood ought to be getting tired of karma fortunes by now.dgatwood ought to be getting tired of karma fortunes by now.dgatwood ought to be getting tired of karma fortunes by now.dgatwood ought to be getting tired of karma fortunes by now.dgatwood ought to be getting tired of karma fortunes by now.dgatwood ought to be getting tired of karma fortunes by now.dgatwood ought to be getting tired of karma fortunes by now.
 
dgatwood's Avatar
 
Posts: 629
Karma: 1623086
Join Date: Jan 2012
Device: iPad, iPhone, Nook Simple Touch
Quote:
Originally Posted by JSWolf View Post
ADE & the ePub 2 spec do not support media queries. I just found the answer on Adobe's support forum and Jim Lester confirmed this.

http://forums.adobe.com/message/4325696?tstart=0
The EPUB 2 specification does not require readers to support any CSS features beyond a subset of CSS2, and ADE does not support very many features outside the required subset (and does not support some of the required subset, either, but again, I digress).

The EPUB 2 specification does require readers to ignore anything that they do not understand, which ADE does not, and thus ADE does not comply with the specification as published.

Quote:
"A conforming Reading System must render all OPS CSS 2.0 required subset properties. A Reading System may support CSS properties beyond the OPS CSS 2.0 required subset, however, any unsupported properties must be gracefully degraded per the CSS 2.0 specification." (OPS 2.0.1 section 1.3.5)
The graceful degradation section says:

Quote:
"A conforming UA must also adhere to the forward-compatible parsing rules, the property and value notation, and the unit notation." (CSS 2.0 spec, Appendix D).
The forward-compatible parsing rules include this:

Quote:
"In some cases, user agents must ignore part of an illegal style sheet. This specification defines ignore to mean that the user agent parses the illegal part (in order to find its beginning and end), but otherwise acts as if it had not been there." (CSS 2.0 spec, Section 4.2)

...

"All levels of CSS -- level 1, level 2, and any future levels -- use the same core syntax. This allows UAs to parse (though not completely understand) style sheets written in levels of CSS that didn't exist at the time the UAs were created. Designers can use this feature to create style sheets that work with older user agents, while also exercising the possibilities of the latest levels of CSS." (CSS 2.0 spec, Section 4.1)
And in particular:

Quote:
"An at-rule consists of everything up to and including the next semicolon ( or the next block, whichever comes first. A CSS user agent that encounters an unrecognized at-rule must ignore the whole of the at-rule and continue parsing after it." (CSS 2.0 spec, Section 4.1.5)
So from the EPUB specification, you can see that @media and @page rules are clearly legal in an EPUB 2.0.1 document. The EPUB spec clearly defines how such rules are to be handled. Specifically, a reader may interpret them, or it may ignore them, at its option, but it must not break.

Last edited by dgatwood; 01-18-2013 at 08:06 PM.
dgatwood is offline   Reply With Quote