Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old Yesterday, 11:46 PM   #1
RbnJrg
Wizard
RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.
 
Posts: 1,576
Karma: 7043711
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
A bug in Sigil?

Hi Kevin and Diap;

In my epubs (3), sometimes I add a javascript to the nav.xhtml file and when I do that, the property "scripted" is not added in the .opf file. That is not a big problem because I can add that property by hand (and I do that), but the issue arises when Sigil open the epub because the property added by me, is erased; I have to do the thing every time that Sigil opens the ebook. Could you fix that in the next Sigil version?

Many thanks in advance.
RbnJrg is offline   Reply With Quote
Old Today, 02:09 AM   #2
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 37,588
Karma: 149865198
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
If you use the ePub3 Tools item in the Tools menu and click on Update Manifest Properties, does this correct the error(s) for you. I haven't tried it with a js linked to the nav document, but it works for standard html documents though I seem to recall at one point, reading that what the navigation document can contain is limited and javascript was not listed as a allowed item. Now if I could find that reference...

Edit: The reference basically stated that since the navigation document is intended to be machine readable, javascript should not be used. Instead make the navigation document hidden and create an dedicated for human use html ToC. So perhaps a nav.xhtml navigation document and a toc.xhtml human intended ToC.

Last edited by DNSB; Today at 02:21 AM.
DNSB is offline   Reply With Quote
Old Today, 08:05 AM   #3
KevinH
Sigil Developer
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: 7,851
Karma: 5449552
Join Date: Nov 2009
Device: many
I will look into it. That property should not be erased if present on loading of any epub if it already exists in the opf manifest for any file.
KevinH is offline   Reply With Quote
Old Today, 04:08 PM   #4
KevinH
Sigil Developer
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: 7,851
Karma: 5449552
Join Date: Nov 2009
Device: many
Yes the SetNavResource() in the OPFResouce is the issue as it just assigns the nav overwriting any other properties.

Also the Epub3 Update Manifest Properties Tool needs to be allowed to work on the nav.

I will try to get a fix for both done soon.
KevinH is offline   Reply With Quote
Old Today, 05:16 PM   #5
RbnJrg
Wizard
RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.RbnJrg ought to be getting tired of karma fortunes by now.
 
Posts: 1,576
Karma: 7043711
Join Date: Mar 2013
Location: Rosario - Santa Fe - Argentina
Device: Kindle 4 NT
Quote:
Originally Posted by DNSB View Post
If you use the ePub3 Tools item in the Tools menu and click on Update Manifest Properties, does this correct the error(s) for you. I haven't tried it with a js linked to the nav document, but it works for standard html documents though I seem to recall at one point, reading that what the navigation document can contain is limited and javascript was not listed as a allowed item. Now if I could find that reference...

Edit: The reference basically stated that since the navigation document is intended to be machine readable, javascript should not be used. Instead make the navigation document hidden and create an dedicated for human use html ToC. So perhaps a nav.xhtml navigation document and a toc.xhtml human intended ToC.
Yes, but the issue is that the property is erased when Sigil loads the epub. And Epubcheck allows the property "scripted" for nav.xhtml (in the .opf, property="nav scripted").
RbnJrg is offline   Reply With Quote
Old Today, 06:56 PM   #6
DNSB
Bibliophagist
DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.DNSB ought to be getting tired of karma fortunes by now.
 
DNSB's Avatar
 
Posts: 37,588
Karma: 149865198
Join Date: Jul 2010
Location: Vancouver
Device: Kobo Sage, Libra Colour, Lenovo M8 FHD, Paperwhite 4, Tolino epos
Quote:
Originally Posted by RbnJrg View Post
Yes, but the issue is that the property is erased when Sigil loads the epub. And Epubcheck allows the property "scripted" for nav.xhtml (in the .opf, property="nav scripted").
I'm not disagreeing that allowing the scripted property for the nav document is not prohibited. What I got from the article I read and made a couple of notes from is that the authors did not recommend using javascript in the nav document since it could cause issues with the renderer's ability to parse the file. Their suggested workaround was a vanilla navigation document that was hidden and a ToC file that could be fancified without needing to worry about the renderer parsing it.
DNSB is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
A new bug in Sigil 0.9.12? RbnJrg Sigil 6 03-07-2019 07:20 AM
Bug in Sigil 0.9.5 PKTC Sigil 6 04-05-2016 12:33 PM
Possible Bug in Sigil 0.8.7 dragon reader Sigil 34 11-19-2015 11:45 AM
possible h1 bug in Sigil 0.6.1? michaelbr Sigil 2 12-04-2012 07:56 PM


All times are GMT -4. The time now is 07:50 PM.


MobileRead.com is a privately owned, operated and funded community.