![]() |
#1 |
Junior Member
![]() Posts: 8
Karma: 10
Join Date: Sep 2014
Device: none
|
Comparison Sigil 0.8.7 & Sigil 0.9.1
Comparison after adding existing files
Sigil 0.8.7 http://y27i.imgup.net/sigil_0_8_449c.jpg Sigil 0.9.1 http://f58i.imgup.net/sigil0_9_1eb42.jpg |
![]() |
![]() |
![]() |
#2 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 28,369
Karma: 203720150
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
A sample is worth a thousand pictures.
It's entirely possible that 0.8.7 was better at converting html5 input to xhtml than 0.9.1. Especially since 0.9.1 doesn't really try to. |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 8,490
Karma: 5703586
Join Date: Nov 2009
Device: many
|
This is all caused by the html tag being wrong for epub.
In Sigil 0.8.7, since it has no epub3 support and it knew how to fix missing doctypes and missing attributes on the html header line ... in other words **always** set it for epub2. Sigil 0.9.1 has started the process of epub3 support and can not guess when importing a single html page what doctype you truly wanted and what to add for the html tag attributes if the original you import do not specify them. If you just pull in raw html that does not have the correct doctype and html attributes, this is what you will get. If you simply edit the doctype and html tag in Sigil-0.9.1, you will see the exact same output. Sigil has no way of knowing if you are going to import html5 vs html4 vs html3.2, nor what target you are looking for epub3 vs epub2 if what you import does not provide a doctype and the required attributes on the html tags to tell it. If this bothers enough people, we could always add a default to epub2 Preference setting so that the doctype and html attributes can always be fixed, or alternatively a plugin to fix and set this as epub2 for all xhtml files. Exactly what DOCTYPE and html tag was provided on the original html file imported (or original epub imported)? KevinH Last edited by KevinH; 12-02-2015 at 12:36 PM. |
![]() |
![]() |
![]() |
#4 |
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 8,490
Karma: 5703586
Join Date: Nov 2009
Device: many
|
That DOCTYPE is okay for html5 in Sigil-0.9.1 and so the html tag is simply missing the xml namespace attribute to tell it how to interpret the xml. This is needed for Preview/BookView to interpret the file as xhtml not some dialect of html.
So edit the <html> tag and add the attribute: xmlns="http://www.w3.org/1999/xhtml" And you will see all appears as normal. KevinH |
![]() |
![]() |
![]() |
#5 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,687
Karma: 24031401
Join Date: Dec 2010
Device: Kindle PW2
|
It appears that there's folder normalization bug in Sigil 0.9.1: stylesheet links are no longer prefixed by ../Styles/.
I've attached a test case. Steps to reproduce this issue: 1. Unpack the files and add blue.xhtml via Add existing file... Result in 0.8.7: Code:
<head>
<title/>
<link href="../Styles/Style0001.css" rel="stylesheet" type="text/css"/>
</head>
Code:
<head> <title/> <link href="Style0001.css" rel="stylesheet" type="text/css"/> </head> Last edited by Doitsu; 12-03-2015 at 03:17 AM. |
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Banned
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 272
Karma: 1224588
Join Date: Sep 2014
Device: Sony PRS 650
|
Hmmm i do not have an 0.8.7 any more, buit i would have expected that the link to the stylesheet is NOT updated as it is exactly already in blue.xhtml
What i didnt know that importing blue.xhtml will automatically add stylesheet.css as well... in that case as stylesheet.css is stored under styles i should have been corrected in blue.xhtml. |
![]() |
![]() |
![]() |
#7 | |
mostly an observer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 1,518
Karma: 987654
Join Date: Dec 2012
Device: Kindle
|
Quote:
(They are usually *.HTM files, because I use a Dos text editor, but I seem to recall that it doesn't matter what the file is actually named.) |
|
![]() |
![]() |
![]() |
#8 | |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 28,369
Karma: 203720150
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
Quote:
Saving the epub and reopening it shows the txt/css link removed from the header. |
|
![]() |
![]() |
![]() |
#9 |
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 8,490
Karma: 5703586
Join Date: Nov 2009
Device: many
|
And the fix for this bug was just committed to master.
Thanks so much for the nice bug report Doitsu! KevinH |
![]() |
![]() |
![]() |
#10 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 28,369
Karma: 203720150
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
I was investigating this morning. I'll have to check the commit and see if I was even looking in the right neighborhood.
![]() |
![]() |
![]() |
![]() |
#11 |
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 8,490
Karma: 5703586
Join Date: Nov 2009
Device: many
|
Hi DiapDealer,
In ImportHTML.cpp since Media file link updating worked, the issue had to be in how we handled stylesheet updating and by comparing the two pieces of code it was clear I simply made the update map key incorrect in the Stylesheet handling code. So the update was never made as it could not find the href to update. Since this was code I had already touched once it was easier for me to find. |
![]() |
![]() |
![]() |
#12 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 5,687
Karma: 24031401
Join Date: Dec 2010
Device: Kindle PW2
|
I've just re-tested the issue with the latest files from master and the problem no longer occurs.
![]() Will Windows users have to wait for Sigil 0.9.2 or are you planning on releasing a minor bug fix release? Last edited by Doitsu; 12-03-2015 at 10:44 AM. |
![]() |
![]() |
![]() |
#13 |
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 8,490
Karma: 5703586
Join Date: Nov 2009
Device: many
|
Doitsu - if you are building your own, there are a few other fixes you might want just committed.
|
![]() |
![]() |
![]() |
#14 |
Sigil Developer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 8,490
Karma: 5703586
Join Date: Nov 2009
Device: many
|
From the looks of things, we probably have enough bugs fixed to wait a week or to and then do a quick Sigil-0.9.2 bug fix only release (assuming DiapDealer has the free time to make the builds).
|
![]() |
![]() |
![]() |
#15 |
Grand Sorcerer
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 28,369
Karma: 203720150
Join Date: Jan 2010
Device: Nexus 7, Kindle Fire HD
|
I shouldn't be pressed for time until closer to Christmas.
|
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Sigil-0.8.900 released for testing - Wait for Sigil-0.8.901 | KevinH | Sigil | 106 | 10-04-2015 10:41 AM |
Sigil on Nook vs Sigil on Kobo vs Sigil on iBook | rosshalde | Sigil | 12 | 11-13-2014 09:34 AM |
Comparison Sigil/ Indesign | GraciousMe | Sigil | 13 | 11-15-2012 10:17 PM |
Sigil 0.3.4 / Sigil 0.4.0 RC1 / Cover in Nook Color | Bertrand | Sigil | 13 | 08-06-2011 04:06 AM |
Sigil 0.3.4 / Problème CSS entre Sigil et iPad | Grivels | Software | 10 | 07-03-2011 09:06 AM |