w3c / epub-specs

Shared workspace for EPUB 3 specifications.
Other
303 stars 60 forks source link

(reading system implementation feedback) multiple renditions mapping: non-CFI target locations cannot be compared/sorted #502

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago

See:

http://www.idpf.org/epub/renditions/multiple/epub-multiple-renditions.html#h.lfq
111oz0g7t

When document targets (nav > ul > li > a@href) are expressed as CFI locations, 
it is trivial to match the reading location in the current rendition with 
entries recorded in the mappings repository, thanks to CFI's inherent 
properties: canonical, and comparable/sortable (without the need to access the 
target DOM). In other words, switching from a spot in a given rendition to the 
corresponding spot in another rendition basically boils down to finding the 
"nearest" recorded location relative to the current reading position, by means 
of trivial arithmetics.

Conversely, when document targets are expressed using the combination of 
epub:rendition="package.opf" and a@href URI with simple fragment identifiers 
(#id), or as Media Fragments, the only way to determine whether the current 
reading position is after or before the said targets, is to load the targeted 
DOM.

So, whilst I can see how Media Fragment URIs (or the absence of URI fragment, 
altogether) can be useful in the particular case of fixed-layout documents 
(i.e. unlike multi-page reflowable documents, it matters less if the 
non-comparable reading locations result in fallback to the beginning of the 
content viewport), I am concerned that the specification does not explicitly 
recommend against using plain #id fragment identifiers. I would suggest going 
as far as making CFI references a MUST conformance requirement for reflowable 
content (a publication may be combining pre-paginated + reflowable, so this 
would obviously apply to individual content documents).

Thoughts?

Original issue reported on code.google.com by daniel.weck on 27 Feb 2015 at 12:45

GoogleCodeExporter commented 9 years ago

Original comment by mgarrish on 9 Mar 2015 at 11:06

danielweck commented 9 years ago

Originally posted by @danielweck (now subscribed)

murata2makoto commented 9 years ago

A proposal is available at:

https://docs.google.com/document/d/1aKqaf5R76MCSsIzsTl81S62ah17-tmh0bMj1ySzPmJs/edit

mattgarrish commented 9 years ago

Proposed text has been integrated.