05-30-2010, 12:50 PM | #1 |
Junior Member
Posts: 7
Karma: 10
Join Date: May 2010
Device: Apple iPad
|
Automating splitting at Chapter Breaks
Hi folks.
I am a new arrival, and new to Sigil, having used Calibre to make 100+ epub ebooks thus far. When my iPad arrived finally, I found that that the epubs did not look as good as some others (more professionally made, I presumed), with lots of letters losing their lowest part (descenders), which got transferred to the top line of the next page. Messy. This problem has vanished when compiling the same strict XHTML source files in Sigil. But ... Unless I am missing a trick, I have to hit the Add Chapter Break button manually at the start of each chapter, and this adds a new file nicely. OK when there are not too many chapters, but the next book I want to compile has over 70 short chapters. My chapter headings in the XHTML source are all enclosed in <h2> tags. What I would love is an automation of my manual work: every <h2> tag (could equally easily be <h3>) gets the Chapter Break stuff added by just pressing a button, and the file splitting just happens while I watch. Any thoughts, anyone? John |
05-30-2010, 01:08 PM | #2 |
Lord of the Universe
Posts: 670
Karma: 737849
Join Date: Jan 2008
Location: Maturin , Venezuela
Device: Sony Reader PRS-505 / PSP
|
Have you tried using search and replace across multiple files along with chapter markers?
Search : <h2> Replace : <hr class="sigilChapterBreak" /> <h2> and after that just press f6 or go to Tools>Split on Chapter markers. Edit: Welcome to mobileread Last edited by Catire; 05-30-2010 at 02:07 PM. |
Advert | |
|
05-30-2010, 01:14 PM | #3 |
Guru
Posts: 971
Karma: 4999999
Join Date: Mar 2009
Location: Rosario, Argentina
Device: SONY PRS-T2, Kindle Paperwhite 11th gen
|
Go to Code view and replace <h2 with <hr class="sigilChapterBreak" /><h2 and after that go to Tools -> Split on SGF Chapter Markers.
Edit: Catire, that was fast!!! |
05-30-2010, 03:12 PM | #4 |
Junior Member
Posts: 7
Karma: 10
Join Date: May 2010
Device: Apple iPad
|
Alas
I have tried that.
The text is a full length novel, and Sigil went into a trance when I tried saving the epub. If I manually do the splitting, the compiling takes just a few seconds. John |
05-30-2010, 07:36 PM | #5 | |
Created Sigil, FlightCrew
Posts: 1,982
Karma: 350515
Join Date: Feb 2008
Device: Kobo Clara HD
|
Quote:
|
|
Advert | |
|
05-31-2010, 12:39 AM | #6 | |
US Navy, Retired
Posts: 9,867
Karma: 13806776
Join Date: Feb 2009
Location: North Carolina
Device: Icarus Illumina XL HD, Kindle PaperWhite SE 11th Gen
|
Quote:
Basic search and replace (on full length novels) like the example above is 85% of what I use Sigil for and thus far it has preformed great. I have never used the Tools -> Split on SGF Chapter Markers feature. Are you saying the search and replace (selecting all HTML files) worked and the Split on SGF Chapter Markers worked but it locked up when went to save the ePub? Good luck working with Valloric to identify the bug you're running into to. Last edited by DoctorOhh; 05-31-2010 at 12:52 AM. |
|
05-31-2010, 12:57 AM | #7 |
Junior Member
Posts: 7
Karma: 10
Join Date: May 2010
Device: Apple iPad
|
Possible Solution
I have just replicated, then cured, the process I described above.
I created an xhtml file with 70+ explicit sigil Chapter Breaks, entered the Metadata, approved the default TOC (70+ <h2> tags), and then pressed the 'Split on Chapter Breaks' button in Tools. Attempted the compile. Result - hanging. Closed Sigil. Started again. Same xhtml file exactly. Same as above, except this time I did a CLT A to the whole source file in Code View to bring it all looking green before I did the 'Split on Chapter Breaks' thing. This time it compiled in seconds! Phew!! This was a relatively short file BTW. The epub is only 83kb. I need to work on this a bit more. I deliberately left out any CSS file, and the only tags used in the whole thing were <h1> <h2> <p> and the <hr class="sigilChapterBreak" /> In due course I may be able to add more. John |
05-31-2010, 05:17 AM | #8 |
Junior Member
Posts: 7
Karma: 10
Join Date: May 2010
Device: Apple iPad
|
Further down the line
I have recompiled a few more source files, using CTL A to engage the whole source file before using F6 to Split on Chapter Breaks, and can confirm that the result is perfect: a surprisingly quick 'Save as epub' outcome.
So I am now committed to Sigil for the rest of my source files. Suggested area for development: could the load be a little quicker, and could the default opening View be Code View? It is obvious that the loading is doing a lot of work, and if this cannot be speeded up, perhaps some kind of progress indicator could be added to reassure one that the program is not hanging. However, this is not a complaint. Many thanks for this product and this forum. John |
05-31-2010, 10:41 AM | #9 |
Created Sigil, FlightCrew
Posts: 1,982
Karma: 350515
Join Date: Feb 2008
Device: Kobo Clara HD
|
Please create an issue on the tracker with this information and the original xhtml/epub file. If I can see it hang, I can fix it.
|
06-01-2010, 03:53 AM | #10 |
Junior Member
Posts: 7
Karma: 10
Join Date: May 2010
Device: Apple iPad
|
Not hanging any more
I have found that I cannot get it too hang any more.
So I am not able to create a bug report. The product is fine in my view. John |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Calibre making unwanted chapter breaks | PatNY | Calibre | 6 | 10-08-2010 10:58 PM |
Remove Chapter Breaks and Search an Entire Document | Marcy | Sigil | 6 | 04-15-2010 01:11 PM |
Help w/ Chapter Breaks | pastorjamie | Calibre | 1 | 02-25-2010 08:30 PM |
Adding chapter breaks by number of pages/lines | raptir | Calibre | 8 | 10-22-2009 01:11 PM |
html2epub: chapter splitting on more than 1 heading level | Portnull | Calibre | 1 | 06-25-2009 10:17 AM |