10-31-2010, 09:17 PM | #76 | |
Guru
Posts: 714
Karma: 2003751
Join Date: Oct 2008
Location: Ottawa, ON
Device: Kobo Glo HD
|
Quote:
But what I really lack at this time is a command line tool, accepting two parameters, input and output ePub file. What I want that tool to do for me is to parse all XHTML elements, and then use those results to do font subsetting for all embedded fonts (cut out all glyphs that are not used in that particular edition). |
|
10-31-2010, 10:30 PM | #77 |
Member
Posts: 10
Karma: 20
Join Date: Sep 2010
Location: Auckland, New Zealand
Device: iPad
|
No - it's a single ePub, but I'm importing the original unzipped files. There are 35 xhtml files, 1 css and 5 images. No problem with the import process itself. Just that Sigil creates new css files for each xhtml file. So I have 35 duplicate css files which seems a tad wasteful.
|
Advert | |
|
11-01-2010, 08:52 PM | #78 |
Guru
Posts: 697
Karma: 150000
Join Date: Feb 2010
Device: none
|
Hmm, I don't think I've had that happen to me, though my usual MO when I do this is to import a single (huge) xhtml with embedded CSS, then create my own separate CSS file using the embedded elements, then split the xhtml into chapters. Which all inherit the same CSS file after splitting.
So I'm guessing here: It is probably because all of the xhtml files contain a reference to the external CSS file, so sigil imports that too, over and over, and presumably renames it to something like Style001.css, Style002.css, etc. Are all the imported CSS files identical (except in name, of course)? If so you could delete all but one, then modify the references in each xhtml file to point to the one css file. Note that you can do search-and-replace with a regular expression ("regex") over all your xhtml files, so all the modifications can be done in one lick, rather than having to edit them all individually. Help on using the power of sigil's regex search and replace is available elsewhere in this forum. Or if you get stuck, ask. ETA: I should read more thoroughly. What I just said above would seem to be the case, and my suggestion is the same (though perhaps more verbose) as that of theducks, a couple of posts previous. Should be an easy fix if our assumptions are correct. Last edited by st_albert; 11-01-2010 at 09:00 PM. |
11-02-2010, 05:09 AM | #79 | |
Member
Posts: 10
Karma: 20
Join Date: Sep 2010
Location: Auckland, New Zealand
Device: iPad
|
Quote:
Very interesting to hear of your workflow/MO. For myself, I prefer to get to the seperate chapter (etc) xhtml files and css as quickly as possible because that is where I feel most comfortable working. In her excellent ePub book, Liz Castro goes into great detail on how to manipulate files from Word or InDesign. I appreciate the effort she's put into it and the clarity with she writes, but I have to say I hate all that 'recovery from...' approach. I see you are right in that theducks said pretty much the same thing as you did, but your (more detailed) version was more immediately understandable. I have a number of thoughts in response, but rather than rambling on in the abstract, I would like to take a few days to experiment further. I'll probably get back on this ! The one thing I would say is that repeatedly importing the same file would seem to me to be a bug in Sigil. But then - I am on an older version. Maybe the latest one has fixed the problem. Thanks again for your advice and especially the offer to help more. Mike |
|
11-02-2010, 11:24 AM | #80 |
Guru
Posts: 697
Karma: 150000
Join Date: Feb 2010
Device: none
|
Hmm, I don't think sigil checks each "new" possible css file to see if it's identical to one it has already imported. It just sees what resources are referred to in each xhtml, and tries to import them too.
|
Advert | |
|
11-03-2010, 08:37 PM | #81 | |
Member
Posts: 10
Karma: 20
Join Date: Sep 2010
Location: Auckland, New Zealand
Device: iPad
|
Quote:
I should probably begin by reiterating that all I'm wanting to do is find a simple way to generate clean, accurate OPF and NCX files once I've got all my xhtml and css done. Since my first post here in September, I have been working on an applescript to make the OPF. I have developed a version that gets me half-way, but still leaves a fair amount of hand coding. As I don't really know applescript (instead relying pretty heavily on snippets picked up from forums such as macscripter.net) I am not able to get it fully functional. Also it's very limited in that it has hard coded POSIX paths which are specific to my machine. I will probably continue to pick away at it as time allows, but for the moment I need something more immediately. Generating an NCX with applescript has defeated me altogether. So - with Sigil, I decided the simplest way around the multiple css file imports was to make a duplicate of my main project folder (with all relevant sub-folders and files) and then do a multifile Replace to remove all links to the css file from every xhtml file. I can then import this modified version into Sigil with no problems. And Sigil then gives me a very nice OPF, which (after un-zipping the ePub) I can put back into my original project. But the NCX is still a little problematic in that the TOC Editor in Sigil doesn't seem to allow for re-ordering. In fact it generates the TOC in alphabetical order and I cannot see a way to change this. Please tell me if I'm wrong about this ! The only solution I can think of is to name every original xhtml file with an ascending numeric system based on the order in which I want them to appear in the book - which is, of course, exactly what Sigil does when it's doing the whole job itself. It's important I think, to use a naming convention with increments of 10 (so: Chap010.xhtml, Chap020.xhtml, etc) in order to allow for later changes and additions. For instance an author might decide at the last minute that he or she wants to put in a dedication page. Thanks to all those who've helped me here and if anyone's got comments or (hopefully, improvements) on this I would love to hear them. Mike |
|
11-03-2010, 09:35 PM | #82 | |
Well trained by Cats
Posts: 30,444
Karma: 58055868
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
|
|
11-03-2010, 11:17 PM | #83 | |
Member
Posts: 10
Karma: 20
Join Date: Sep 2010
Location: Auckland, New Zealand
Device: iPad
|
Quote:
Many thanks. |
|
11-04-2010, 12:02 AM | #84 | |
Well trained by Cats
Posts: 30,444
Karma: 58055868
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
Say your Entry says "Bapter 7" You can change it in the TOC editor to "Chapter 7" and it makes the change in the main document. Anything you do in the TOC editor, affects the main document. Un-ticking, makes a notation in the h# tag to hide from Sigil TOC. The thing you CAN NOT do is make the TOC say one thing (from the editor) and have another value in the actual document. For that, you need to manually add title="BlahBlah" to the tag, which overides the normal text. |
|
11-04-2010, 07:16 PM | #85 |
Guru
Posts: 697
Karma: 150000
Join Date: Feb 2010
Device: none
|
Regarding the multiple css files issue, this appears to have been addressed in the new sigil 0.3.0 FINAL release.
Just announced today. See http://sigildev.blogspot.com/2010/11/030-final.html |
11-04-2010, 09:38 PM | #86 | |
Member
Posts: 10
Karma: 20
Join Date: Sep 2010
Location: Auckland, New Zealand
Device: iPad
|
Quote:
|
|
11-05-2010, 01:03 AM | #87 | |
Guru
Posts: 697
Karma: 150000
Join Date: Feb 2010
Device: none
|
Quote:
Else, buy a cheap PC (and put linux on it). [sardonic] You can't stop progress. [/sardonic off] |
|
11-05-2010, 02:13 AM | #88 | |
Member
Posts: 10
Karma: 20
Join Date: Sep 2010
Location: Auckland, New Zealand
Device: iPad
|
Quote:
Having said that, this old G5 hums along very sweetly. After 25 years on PCs I switched to Mac about 18 months ago. Exercising great self-restraint, I will refrain from giving you the usual "Mac-convert" quotes, but I will say that I weep now thinking of all those wasted years and all that unnecessary gnashing of teeth. |
|
11-05-2010, 06:32 AM | #89 | |
Created Sigil, FlightCrew
Posts: 1,982
Karma: 350515
Join Date: Feb 2008
Device: Kobo Clara HD
|
Quote:
Last edited by Valloric; 11-05-2010 at 06:35 AM. |
|
11-05-2010, 06:26 PM | #90 | |
Member
Posts: 10
Karma: 20
Join Date: Sep 2010
Location: Auckland, New Zealand
Device: iPad
|
Quote:
Sigil is a great piece of software and it leaves me gobsmacked that you make it available free. If you can accept my apology, I would actually be very, very interested to learn something about the limitations of PPCs. Mike Last edited by RealImages1; 11-05-2010 at 09:19 PM. |
|
Tags |
epub application, epub creation, epub editor, wishlist |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
tools for epub creation | Toxaris | ePub | 15 | 03-05-2010 05:54 AM |
creation tools for Mac? | nathanb | Workshop | 1 | 09-11-2009 11:33 PM |
on-the-fly epub creation | ilovejedd | ePub | 19 | 04-16-2009 08:36 PM |
Half of book missing after running converter tools, ideas? | ficbot | Other formats | 0 | 04-11-2009 01:42 PM |
epub creation tools | jbenny | ePub | 20 | 03-13-2009 01:30 PM |