Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 07-23-2014, 01:11 PM   #91
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,630
Karma: 5433388
Join Date: Nov 2009
Device: many
Hi theDucks,

Are there really epubs out there that use the exact same filename (including extension) more than once in the same ebook? Or are you talking about importing raw html when just starting to create the book?

if the latter, then eventually you want to have all of the text filenames be unique correct? If so, there may be a way to change Sigil to add a numeric unique identifier at the end of the filename (just before the extension) for files the exact same name being imported. Similar to how Mac OS X handles things when you drag a file of the same name ot the same folder.

Would that be of any value, or would you really like to have duplicate file names just placed in multiple folders?

If the latter, I am not sure that is a good idea in the long run. Just like some ebook editors who repeat identical target id attributes in every file ... it is just asking for trouble. Given how Kindlegen and other packages jam all of the source into one file, then extract the skeletons and the fragments repeating ids and repeating filenames would not be a good mix, imho.

KevinH

Quote:
Originally Posted by theducks View Post
DiapDealer has it.

Sigil has a single OEBS folder structure (Text, Images, Styles)

You can NOT import multiple HTML safely with any overlapping path filenames because Sigil flattens the import, then shoves those into the above structure. All filenames must be unique to survive a Sigil import.

Last edited by KevinH; 07-23-2014 at 01:14 PM.
KevinH is offline   Reply With Quote
Old 07-23-2014, 01:43 PM   #92
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,630
Karma: 5433388
Join Date: Nov 2009
Device: many
Hi All,

One last bug fix. Here is a patch to the latest Sigil trunk (master) on github, to tell Tidy that the svg image tag is not a block tag but is instead an inline tag that is always empty (ie. to tell Tidy to make it a self-closing tag).

This bug is triggered when using svg images for covers and things when passing it to Kindlegen. Kindlegen's XML parser knows that svg image tags are inline and empty and so it barfs over finding empty < image blah blah > < / image > tags when Kindlegen thinks they should instead be valid only as:< image blah blah / >.

This was my last itch to scratch, but I will look at other fixes and minor changes for Sigil when I get more free time later on this Summer.

Hope this Helps,

KevinH
Attached Files
File Type: zip svg_image_tag_fix.patch.zip (1.3 KB, 164 views)
KevinH is offline   Reply With Quote
Old 07-23-2014, 01:49 PM   #93
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 29,779
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Quote:
Originally Posted by KevinH View Post
Hi theDucks,

Are there really epubs out there that use the exact same filename (including extension) more than once in the same ebook? Or are you talking about importing raw html when just starting to create the book?

if the latter, then eventually you want to have all of the text filenames be unique correct? If so, there may be a way to change Sigil to add a numeric unique identifier at the end of the filename (just before the extension) for files the exact same name being imported. Similar to how Mac OS X handles things when you drag a file of the same name ot the same folder.

Would that be of any value, or would you really like to have duplicate file names just placed in multiple folders?

If the latter, I am not sure that is a good idea in the long run. Just like some ebook editors who repeat identical target id attributes in every file ... it is just asking for trouble. Given how Kindlegen and other packages jam all of the source into one file, then extract the skeletons and the fragments repeating ids and repeating filenames would not be a good mix, imho.

KevinH
Kevin
Yes, I have seen this structure :

chapter1/body.html
chapter1/Images/image001.jpg
chapter1/Images/image002.jpg
chapter1/Images/image003.jpg

chapter2/body.html
chapter2/Images/image001.jpg
chapter2/Images/image002.jpg

chapter3/body.html
chapter3/Images/image001.jpg
chapter3/Images/image002.jpg
chapter3/Images/image003.jpg


SEEN, not agree with the practice
and there is no guaranteed parity between images of the same names
theducks is online now   Reply With Quote
Old 07-23-2014, 01:52 PM   #94
Tex2002ans
Wizard
Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.Tex2002ans ought to be getting tired of karma fortunes by now.
 
Posts: 2,297
Karma: 12126329
Join Date: Jul 2012
Device: Kobo Forma, Nook
Quote:
Originally Posted by KevinH View Post
Would that be of any value, or would you really like to have duplicate file names just placed in multiple folders?
Oh yeah, that fix would be perfect, and that is DEFINITELY the use case where I come across this problem the most often, when I pull HTML from a site, and then try to import it into Sigil.

Always have to rename files outside of Sigil, and then reimport.
Tex2002ans is offline   Reply With Quote
Old 07-23-2014, 02:07 PM   #95
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,630
Karma: 5433388
Join Date: Nov 2009
Device: many
Hi theducks,

Quote:
Originally Posted by theducks View Post
Kevin
Yes, I have seen this structure :

chapter1/body.html
chapter1/Images/image001.jpg
chapter1/Images/image002.jpg
chapter1/Images/image003.jpg

chapter2/body.html
chapter2/Images/image001.jpg
chapter2/Images/image002.jpg

chapter3/body.html
chapter3/Images/image001.jpg
chapter3/Images/image002.jpg
chapter3/Images/image003.jpg


SEEN, not agree with the practice
and there is no guaranteed parity between images of the same names
Okay, that makes the practice more concrete to me. Using the above example, could you live with the following flattening approach to fit the current Sigil file structure scheme?

In Text:
chapter1_body.html
chapter2_body.html
chapter3_body.html

In Images:
chapter1_Images_image001.jpg
chapter1_Images_image002.jpg
chapter1_Images_image003.jpg
chapter2_Images_image001.jpg
chapter2_Images_image002.jpg
chapter3_Images_image001.jpg
chapter3_Images_image002.jpg
chapter3_Images_image003.jpg

If so, and *if* there is some easy way to detect your use case upfront before import starts, then there should be a way to take the unique path from the manifest and covert it to a unique file name as above. And then go through and fix all of the relative links in all of the text files to the images and to other places in themselves. Sigil does this right now, it just doesn't look walk the epub contents first looking for duplicate files.

By the way, does it do the same thing with chapter specific css files too?

I have not looked at the Sigil file import code at all but I will look at it and see if there is something I can do.

If not ... if you are okay with using python tools in your work flows, I could whip up a epub converter that does the above and writes it out to a new epub that you can import and play with in Sigil. The old version would then be available to check against the original.

Just let me know. I can't do this right now, but I can put it on my todo list for my free time over the remainder of the summer.

KevinH
KevinH is offline   Reply With Quote
Old 07-23-2014, 02:50 PM   #96
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 29,779
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
CSS, the whole 9 yards. the book appears to be built from standalone chapters (in many cases, the CSS is the same.... but no assurances

Personally, I don't care what get done , just so it does not break.
having some intelligence (like you chow) as to what the original was will always help to debug a book.
theducks is online now   Reply With Quote
Old 07-23-2014, 04:32 PM   #97
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,630
Karma: 5433388
Join Date: Nov 2009
Device: many
Hi,

I have found the right place in the code where the new filename is generated and the code seems to add a unique version number so that all names are now unique.

So the problem must come from the different relative paths due to different chapter folders.

Will you please post for me a testcase.epub that causes the problem you are seeing? That way I can watch the code run in a debugger to find out where exactly the difficulties lie.

Thanks,

KevinH

Quote:
Originally Posted by theducks View Post
CSS, the whole 9 yards. the book appears to be built from standalone chapters (in many cases, the CSS is the same.... but no assurances

Personally, I don't care what get done , just so it does not break.
having some intelligence (like you chow) as to what the original was will always help to debug a book.
KevinH is offline   Reply With Quote
Old 07-23-2014, 04:38 PM   #98
theducks
Well trained by Cats
theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.theducks ought to be getting tired of karma fortunes by now.
 
theducks's Avatar
 
Posts: 29,779
Karma: 54830978
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
Sorry, but I did not keep a, unmodified testcase version (It was a real long time ago that I ran into the issue).
theducks is online now   Reply With Quote
Old 07-23-2014, 04:52 PM   #99
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,630
Karma: 5433388
Join Date: Nov 2009
Device: many
Edit: No need for any test cases. I created my own and the latest sigil had no trouble importing it or handling it in any way.

So that was a "bug" that was already squashed.

Sigil handles that case just fine now.

Last edited by KevinH; 07-23-2014 at 05:39 PM.
KevinH is offline   Reply With Quote
Old 07-24-2014, 07:55 AM   #100
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,630
Karma: 5433388
Join Date: Nov 2009
Device: many
Hi,
My svg image fix patch has also now been committed to the trunk of Sigil. So all my "issues" have now been fixed. I will look into the warning message for regenerating toc when page numbers are used when I get more free time.

I will build and post a Mac OS X Mavericks build of the current trunk later this week in case anyone wants to use it.

Hope this helps,

KevinH
KevinH is offline   Reply With Quote
Old 07-24-2014, 12:12 PM   #101
Arios
A curiosus lector!
Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.Arios ought to be getting tired of karma fortunes by now.
 
Arios's Avatar
 
Posts: 463
Karma: 2015140
Join Date: Jun 2012
Device: Sony PRS-T1, Kobo Touch
KevinH, just want to thank you: this is a nice initiative for a very good app.

Between Sigil and Calibre Edit Book, I share DiapDealer's opinion: I'm amazed by the work did by Kovid in such a small time, but I always end up to use Sigil.

PS Thank you also to DiapDealer for the new Windows build: AFAIK, it works well.
Arios is offline   Reply With Quote
Old 09-03-2014, 06:23 PM   #102
WallyTbull
Junior Member
WallyTbull began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Sep 2014
Device: Kindle Fire
Kevin, does this build require QTt5.3.1 to be installed in order to run in Mavericks 10.9.4?
WallyTbull is offline   Reply With Quote
Old 09-03-2014, 06:53 PM   #103
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,630
Karma: 5433388
Join Date: Nov 2009
Device: many
Hi,

No, it is bundled as part of the build of Sigil.

Kevin
KevinH is offline   Reply With Quote
Old 09-04-2014, 11:47 AM   #104
WallyTbull
Junior Member
WallyTbull began at the beginning.
 
Posts: 2
Karma: 10
Join Date: Sep 2014
Device: Kindle Fire
Quote:
Originally Posted by KevinH View Post
Hi,

No, it is bundled as part of the build of Sigil.

Kevin
Kevin,
Your work is truly appreciated. A number of us were having serious problems with 7.4 and OS X 10.9.4. It's not only a matter of crashing but also corrupt epubs. On behalf of myself, those who have found your solution, and those who will come. A big Thank You!
Wally
WallyTbull is offline   Reply With Quote
Reply

Tags
crashes, mavericks, osx 10.9.4, sigil 7.4


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
0.7.4 on Maverick crashing Geoff_C8 Sigil 6 01-17-2014 01:40 AM
Sigil keeps crashing kksdragons Sigil 18 11-14-2013 06:20 AM
Sigil is crashing in Windows lindaw2396 Sigil 4 04-22-2013 05:42 PM
crashing and crashing bookjunky Calibre 2 01-16-2011 05:59 PM
0.7.9 crashing on OS X? riverteeth Calibre 7 07-21-2010 11:02 AM


All times are GMT -4. The time now is 03:22 AM.


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