View Single Post
Old 11-21-2014, 05:15 PM   #25
KevinH
Wizard
KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.KevinH ought to be getting tired of karma fortunes by now.
 
Posts: 3,425
Karma: 2063254
Join Date: Nov 2009
Device: many
Hi Jonathan,

Quote:
I have tried the same file again with version 0.1.8 of ePub3-itizer, also updating the quickparser.py and have run the output through ePUBcheck once more. This still produces similar errors. However, nav.xhtml now opens cleanly in an external editor and I can see what the issue is, which is that the nested lists should each be contained in their own list item of the parent list (or preceding list in the hierarchy), whereas they appear as ordered lists in between list items instead of inside of one.
Yes I finally found the spec that showed it nested inside <li> tags. To me that is a very silly way to create the nesting for the nav.xhtml but it is the spec ...
so I think I have finally figured this one out (but I am not 100% sure). At least this new version should not be any worse than the older one!

Quote:
Interestingly if I open the page as a standalone item in any of the main web browsers all show the nested list as it should appear and do not report any errors. Technically though it is wrong, which must be what ePUBcheck doesn't like about it.
Yes, and I like my version better ;-) but ... the spec it must be.

Quote:
I am also getting and error for epub:type="title-page" in the Guide saying it is an undefined property, which when I look is possibly because the same href item has been put for every landmark entry. The last page in the eBook has been repeated for each of them.
Yes, the href was a bug and I fixed that. But I have found multiple lists of allowed vocabulary for the epub:type element.

I have gone with this list:

http://www.idpf.org/accessibility/gu...l/sections.php

And it lists titlepage instead of title-page.

There is also this much much longer list:

http://www.idpf.org/epub/vocab/structure

but that list is getting so long it is absurd. It also lists "titlepage" not "title-page"

So I have translated the "title-page" which is legal opf2 guide to "titlepage".
I used the first link to form the basis for the list I am supporting and have reworkeing the guide types to epub:type mapping. BTW: since the opf2 guide elements allow guide types of "other-*", I have set things up so that "other-*" prefixes will be mapped to the "*" part if it exists in the legal vocabulary of epub:types given by the first list I found.

Quote:
I have tried it again with a slightly more complex ePUB2 file, which produces similar errors in the nav.xhtml file (and obviously still complains about the DOCTYPE in the toc.ncx). This also gives some errors in the .opf file for the use of dc:type, which is in the original and doesn't raise an error when validated as ePUB2. Without checking the specifications I am not sure if this is actually an error in ePUB3 or not.
I checked this and dc:type has gone from a pretty much free form field in epub2 to be quite restricted when used in epub3.

See: http://www.idpf.org/epub/vocab/package/types/

So I have changed the code to look for one of the approved types and if not, then simply skipping that dc:type metadata

Quote:
If it might help to have some sample files to test with, either for ePUB3-itizer or for Sigil's further development, contact me directly. They would have to be provided on a non-disclosure basis though.
Understood and I will probably take you up on that especially if my nav.xhtml is still messed up in your testing.

Thank you for all of your testcases and bug reports!

Please see the first post for the latest ePub3-itizer_v019.zip which will hopefully (finally) get the nav correct.

Take care,

Kevin
KevinH is offline   Reply With Quote