10-27-2014, 10:26 PM | #1 |
Wizard
Posts: 2,608
Karma: 3000161
Join Date: Jan 2009
Device: Kindle PW3 (wifi)
|
pop-up endnotes: glory in action
Hi
I could experience the huge difference on my Kobo Glo touchscreen (v. 2.8.1. from July 2013) between usual endnotes and pop-up endnotes. It's a life changer, the former ones being an haphazard hit and miss process (when it's recommended to use big note calls, preferably between brackets) and the latter when your ebook reader becomes suddenly very precise and smooth and does not miss any endnote, however small the endnote call can be. The problem and the source of my question is that I can enjoy the display of pop-up endnotes only with .kepub.epub. True the pop-up window could be bigger but this is another question. What I enjoy immensely is the fact that my rate of hit and miss fell down to 0%. The question is: what is the code? I know kepub is a proprietary format and the files kobo.css and kobo.js have not been published. What you find when you open a .kepub.epub is a koboSpan with an id around the link and that's all. So it seems that the kepub renderer engine takes the brunt of it. But I find hard to believe that the code can be shrouded in mystery for such a "normal" thing. I would like to include - say on an external stylesheet - a code for pop-up notes compatible with EPUB2s. Who knows something about it? PS: the screen is indeed dirty... Last edited by roger64; 10-28-2014 at 12:21 AM. |
10-27-2014, 11:04 PM | #2 |
Grand Sorcerer
Posts: 12,594
Karma: 74358024
Join Date: Nov 2007
Location: Toronto
Device: Libra H2O, Libra Colour
|
I don't think it has anything to do with the code in the ePub; rather it has to do with HOW the ACCESS engine that is used for rendering Kobo format ePubs works.
|
Advert | |
|
10-28-2014, 05:34 PM | #3 |
Addict
Posts: 398
Karma: 96448
Join Date: Dec 2013
Device: iPad
|
EPUB2 is not a valid epub if you include Javascript files, if however, you do like to try it out just use a
Code:
<div style="display:none"> Otherwise if you want that kind of pop-up in an EPUB3 you should use aside and noteref, use this tutorial Last edited by odedta; 10-28-2014 at 05:36 PM. |
10-28-2014, 05:51 PM | #4 |
Wizard
Posts: 2,608
Karma: 3000161
Join Date: Jan 2009
Device: Kindle PW3 (wifi)
|
@odedta
Thanks for your link and this reply. I think the problem will soon be solved. Work on writer2xhtml EPUB converter has been resumed for two months after a two and a half years break and a brand new version 1.4 beta has been released on the 22d of October. It supports already html5 exports and will soon provide for version 1.6 a full EPUB3 support. http://writer2latex.sourceforge.net/index1.html http://sourceforge.net/projects/writer2latex/ This program is written in Java and including a script inside will be authorized. There is also a way to do it using CSS only but it does not look so easy... http://www.wks.fr/Creer-une-popup-100-CSS.html Last edited by roger64; 10-28-2014 at 07:28 PM. Reason: link |
10-29-2014, 04:39 AM | #5 |
Addict
Posts: 398
Karma: 96448
Join Date: Dec 2013
Device: iPad
|
The CSS version will not work in electronic book readers because they use the :hover selector and you can't really have a pointer to hover over elements, it will however, work in pc/mac (anything with a mouse).
I really don't understand why you think this is such a big deal, it takes like 30 seconds to setup this kind of pop-up in an EPUB3 |
Advert | |
|
10-29-2014, 07:37 AM | #6 | |
Wizard
Posts: 2,608
Karma: 3000161
Join Date: Jan 2009
Device: Kindle PW3 (wifi)
|
Quote:
I have been fiddling uselessly for nearly two years with endnotes on my Kobo Glo using the ADE renderer. Believe me, for this reason, this is a big deal. Even if the JS script looks simple to write (for you), between writing it and using it on my ebook reader, God put the renderer... does it mean we'll need to discard the old ADE renderer and wait either for a new version of it or install a new renderer (like say koreader)? My knowledge about it is nil so I'll really appreciate some more comments. |
|
10-29-2014, 02:41 PM | #7 |
Addict
Posts: 398
Karma: 96448
Join Date: Dec 2013
Device: iPad
|
I really have no idea about Kobo, here is the code for both ways to show pop-ups:
Code:
<?xml version='1.0' encoding='utf-8'?> <html xmlns:epub="http://www.idpf.org/2007/ops" xmlns="http://www.w3.org/1999/xhtml"> <head> <title>Demo ePub3 Popups</title> <script> function tooltip_open(x) { document.getElementById(x).style.display="block"; } function tooltip_close(y) { document.getElementById(y).style.display="none"; } </script> <style> .tooltip { background: rgb(242, 242, 242); border: 2px solid #a1a1a1; border-radius: 25px; display: block; z-index: 9999; position: relative; padding: 0 10px 0 10px; display: none; } </style> </head> <body> <h1>Javascript example</h1> <p><a href="#tooltip1" onclick="tooltip_open('tooltip1')">CLICK ME</a></p> <div class="tooltip" id="tooltip1"> <p>LoL this is a popup LoL</p> <p><a href="#close" onclick="tooltip_close('tooltip1')">[X]</a></p> </div> <a id="close"></a> <h1>Aside example</h1> <p><a epub:type="noteref" href="#n1">CLICK ME</a></p> <aside epub:type="footnote" id="n1"> <p>LoL this is a popup LoL</p> </aside> </body> </html> |
10-29-2014, 06:32 PM | #8 |
Wizard
Posts: 2,608
Karma: 3000161
Join Date: Jan 2009
Device: Kindle PW3 (wifi)
|
Thanks a lot for this code. I will study it and make use of it as soon as possible.
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Pop-up endnotes | crutledge | ePub | 16 | 06-17-2014 03:41 AM |
The Guide to Fantasy Football Glory | sportsfan000 | Self-Promotions by Authors and Publishers | 0 | 06-09-2013 03:15 PM |
Endnotes | Siam | Sigil | 14 | 03-17-2013 02:05 PM |
Glory while it lasts .... | Kevin2088 | Amazon Kindle | 6 | 04-17-2009 02:12 PM |