03-02-2017, 05:03 PM | #16 |
Read, don't parrot.
Posts: 224
Karma: 110242
Join Date: Apr 2011
Device: Kindle Fire, Kobo Touch, Aldiko for Android
|
OMG, I've been using Sigil for years and I never noticed the F10 preview before (similar to Dreamweaver's Split View). Ha, ha -- I'm such a dork! I've been so used to switching back and forth between Book View and Code View that I never looked for anything else. Ya learn something new every day.
BTW, I tried it out. But now I have a new question: In the lower right-hand corner an error displays. (See SS.) It appears to be somehow related to my browser? The file is otherwise fine (ie., passes validation). What might it be? I haven't figured out how to get Sigil to tell me where the error is. And the error disappears when I hide/unhide the console. It then reappears if I close down Preview and reopen it. Another mystery. |
03-02-2017, 05:36 PM | #17 |
Grand Sorcerer
Posts: 28,153
Karma: 201666666
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
That's just the html Inspector widget. Some people have a use for it, but I don't. If you don't need to inspect the various html element in that way, just grab the divide between the Preview Window and the Inspector widget and squeeze the Inspector down to nothing.
I have no idea what that particular error is, but it has nothing to do with epub, IMO. |
Advert | |
|
03-02-2017, 06:27 PM | #18 |
Sigil Developer
Posts: 8,289
Karma: 5568878
Join Date: Nov 2009
Device: many
|
That indicates that some javascript is trying to access $.browser.msie but that has been removed from jQuery. I will try to track down if that is something in the Sigil code or something in QtWebkit.
It can be safely ignored unless you are using your own javascript in a epub3 ebook. |
03-02-2017, 07:09 PM | #19 |
Read, don't parrot.
Posts: 224
Karma: 110242
Join Date: Apr 2011
Device: Kindle Fire, Kobo Touch, Aldiko for Android
|
Thanks. That's a relief.
BTW, with regard to my initial post, is there a way to specify the bullet type in CSS? I got Code:
.circle {list-style-type:circle;} .disc {list-style-type:disc;} I found another HTML site that recommends list-style-type:upper-latin and list-style-type:lower-latin, but those don't work either. When I google "XHTML list types", I don't get anything beyond the basics. |
03-02-2017, 07:12 PM | #20 |
A Hairy Wizard
Posts: 3,253
Karma: 20040707
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 15/11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
|
list-style-type:upper-latin or list-style-type:upper-alpha
found at W3schools: https://www.w3schools.com/csSref/pr_list-style-type.asp edit: Works great...make sure it's all lower case. Of course, you can put this in a class instead of an in-line style. As in: Code:
<ol style="list-style-type:upper-latin"> <li>asdsad</li> <li>asdsad</li> <li>asdsad</li> <li>asdsad</li> <li>asdsad</li> </ol> or .upperlatin {list-style-type:upper-latin} <ol class="upperlatin"> <li>asdsad</li> <li>asdsad</li> <li>asdsad</li> <li>asdsad</li> <li>asdsad</li> </ol> Last edited by Turtle91; 03-02-2017 at 08:29 PM. |
Advert | |
|
03-02-2017, 07:59 PM | #21 | |
Sigil Developer
Posts: 8,289
Karma: 5568878
Join Date: Nov 2009
Device: many
|
Our copy of the jquery plugin wrapSelection.js uses the now deprecated $.browser.msie interface which in our case (webkit) is always false anyway.
I will edit that javascript to remove the unneeded code for old ie explorer. That should make your error go away. KevinH Quote:
|
|
03-02-2017, 11:40 PM | #22 |
Read, don't parrot.
Posts: 224
Karma: 110242
Join Date: Apr 2011
Device: Kindle Fire, Kobo Touch, Aldiko for Android
|
Hi Turtle--
I tried the second one, but Sigil, ADE, Kindle -- none of them recognize Code:
{list-style-type:lower-latin} |
03-03-2017, 03:00 AM | #23 | |
Grand Sorcerer
Posts: 5,659
Karma: 23456789
Join Date: Dec 2010
Device: Kindle PW2
|
Quote:
Code:
<ol style="list-style-type: lower-alpha;"> <li>Veni</li> <li>Vidi</li> <li>Vici</li> </ol> <ol style="list-style-type: lower-latin;"> <li>Cogito</li> <li>Ergo</li> <li>Sum</li> </ol> |
|
03-03-2017, 01:26 PM | #24 | |
Read, don't parrot.
Posts: 224
Karma: 110242
Join Date: Apr 2011
Device: Kindle Fire, Kobo Touch, Aldiko for Android
|
Quote:
I have my days... |
|
03-03-2017, 02:34 PM | #25 |
Grand Sorcerer
Posts: 28,153
Karma: 201666666
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
|
03-03-2017, 03:23 PM | #26 |
Sigil Developer
Posts: 8,289
Karma: 5568878
Join Date: Nov 2009
Device: many
|
Okay, removed the now obsolete use of $.browser.msie in Sigil's version of jquery.wrapSelection.js so it should remove any javascript errors from the Inspector Console window. It does under my tests.
That just leaves how to handle underline and strike. I can easily now force BookView to add spans with in-line styles to prevent Sigil from introducing "strike" when in BookView and using "u". If we go ahead with those changes, Sigil, even in BookView will at least generate 100% correct code although ugly and ungainly. BookView will then handle thigns differently than CodeView but I am okay with that given that the code BookView generates at times is truly awful. I would like to get a fix in the tree for use of strike at least (deprecating u and then undeprecating it is just stupid, so I don't really care about use of "u" or not). DiapDealer, what do you think? |
03-03-2017, 03:33 PM | #27 | |
Grand Sorcerer
Posts: 28,153
Karma: 201666666
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
Quote:
It would seem to be the best of both worlds if a user could ultimately decide for themselves between ugly-but-compliant and clean-(and functional)-but-technically-in-violation-of-specs, no? Last edited by DiapDealer; 03-03-2017 at 03:38 PM. |
|
03-03-2017, 03:45 PM | #28 |
Sigil Developer
Posts: 8,289
Karma: 5568878
Join Date: Nov 2009
Device: many
|
Yes just before emiting the page open signal in the following method:
BookViewEditor::CustomSetDocument(const QString &path, const QString &html) You can add a line: ExecCommand("styleWithCSS", "true"); |
03-03-2017, 03:53 PM | #29 |
Grand Sorcerer
Posts: 28,153
Karma: 201666666
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
Sounds pretty simple (and I see the effect when compiled). Do you think it makes good sense? If so, we just need to decide where to add the setting in the prefs (unless an environment variable makes more sense?).
EDIT: looks like that would affect all the GUI formatting buttons ... making them all styled spans (including italics and bold). I don't use the buttons myself (in Code View or Book View), so it doesn't matter to me. Last edited by DiapDealer; 03-03-2017 at 04:01 PM. |
03-03-2017, 04:02 PM | #30 |
Sigil Developer
Posts: 8,289
Karma: 5568878
Join Date: Nov 2009
Device: many
|
If we add a setting, should we then also try and honour it in CodeView as well?
Most of CV formatting code is done manually, so we should be able to make it use the span and inline style approach as well for underline, strike, subscript, superscript, etc, etc after checking the setting. A bit more work but it would at least allow the user to control things in both BookView and CodeView. What do you think, worth the trouble or just hard code the horrible spans for BookView only? |
Tags |
epub2, epub3, epubcheck, fail validation |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Validation Error epub3 | soparch | ePub | 2 | 12-02-2015 12:38 AM |
EPUB3 footnote validation | roger64 | Workshop | 11 | 06-03-2015 08:56 AM |
Epub3 XHTML Validation epub3 | Ramesh Arpitha | ePub | 5 | 06-30-2014 09:32 PM |
Validation errors on epub3 sheet music document | maestroc | ePub | 9 | 11-05-2013 07:43 PM |