Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 05-21-2015, 04:21 AM   #1
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 668
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Editing multiple books

Sometimes I have a group of ebook files that I want to put all in a consistent style, though they came from different sources.

So I just do them one by one (or with two open at once) and do a lot of cut and pasting between the css files, etc.

Is there a way to edit several books at once?
E.g. combining them into one file, editing and and then splitting them again without having to rebuild all the structure?

I have one omnibus ebook (combining 20 books) that if I open it as a zip, I can see each book is a separate folder. But opening it in Sigil, it doesn't show the subfolders, all the files are listed together, and it's impossible to make sense of. Nevertheless, it works in ebook readers.
AlanHK is offline   Reply With Quote
Old 05-21-2015, 10:15 AM   #2
Turtle91
A Hairy Wizard
Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.Turtle91 ought to be getting tired of karma fortunes by now.
 
Turtle91's Avatar
 
Posts: 3,102
Karma: 18727053
Join Date: Dec 2012
Location: Charleston, SC today
Device: iPhone 11/X/6/iPad 1,2,Air & Air Pro/Surface Pro/Kindle PW & Fire
Omnibus books simply need to be named properly for them to be in order. I use:
Bk1-cover
Bk1-Ch1
Bk1-Ch2
...
Bk2-cover
Bk2-Ch1
etc.

However, I don't like putting more than 3-4 books in the same file depending on the length of each book. It could make the file size too large which could have adverse effects on older devices.

It is simple to make books appear the same way. Just use the same css stylesheet on all the books. Once you have created your css the way you want it, you can right click and Save As. Then in the other books you can import the same css file....don't forget to link each html file to your new css file.

The HTML files should be kept VERY CLEAN with minimal classes (only those that are necessary) and (try really hard for) zero inline styles.

Sorta like this:
Code:
<body>
<h2>Chapter Title</h2>
<p class="first">First paragraph</p>
<p>2nd para</p>
<p>3rd para</p>
<p class="SecBrk">Scene break paragraph</p>
<p>Next para with <em>a phrase emphasized in italic</em></p>
</body>


css:
h2          {text-indent:0; text-align:center; margin:1em auto;
             font-style:bold; font-size:1.3em; font-family:serif}
p           {text-align:left; text-indent:1.2em; margin:0}
p.first     {text-indent:0}
p.SecBrk    {text-indent:0; margin-top:2em}
em          {font-style:italic}
(obviously adjust the css to your taste)


I think it is pretty silly to put a class on every paragraph just to assign the default class such as:
Code:
<p class="para">One of 5000+ paragraphs</p>

css:
p.para {text-align:left; text-indent:1.2em; margin:0}
Save class assignments for elements that are NOT the default style. That keeps things clean and saves the device/app from having to decode unnecessary styling.

If you consistently use simple html coding then using the same css file will make all the books look similar.

I hope that helps!

Cheers,
Turtle91 is offline   Reply With Quote
Advert
Old 05-21-2015, 01:27 PM   #3
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 668
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by Turtle91 View Post
However, I don't like putting more than 3-4 books in the same file depending on the length of each book. It could make the file size too large which could have adverse effects on older devices.
I only want to combine the books temporarily, while I'm working on them. I want separate books again at the end.



Quote:
It is simple to make books appear the same way. Just use the same css stylesheet on all the books.
Yes, I know that.

I'm not creating books from scratch, I'm combining books from different sources, that each may have been coded in a different way, not just have different CSS definitions for the same styles.

95% are going to end up as just <p> after I clean up the spaghetti code. Then it's sorting out the rest.


What I need to do is transform the HTML. I can just paste in my own CSS, it's converting al the weird spans and divs and calibrexx styles to something rational that is the tedious part I want to speed up by doing all in one file. So I can quickly make sure all the heads are consistent throughout, for instance.

I can rename each book's files uniquely and combine them if there isn't an easier method.

Last edited by AlanHK; 05-21-2015 at 01:30 PM.
AlanHK is offline   Reply With Quote
Old 05-21-2015, 01:58 PM   #4
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,421
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
I guess you could use calibre's EPUBMerge/Split plugins... but they put each book in a separate folder of the resulting EPUB. Sigil automatically flattens that and restructures the file tree, which can sometimes badly mess up such a book. IIRC there were filename collisions.
Probably what happened to your omnibus.
calibre's editor is immune to that, because it does not enforce structure automatically.
eschwartz is offline   Reply With Quote
Old 05-21-2015, 02:52 PM   #5
AlanHK
Guru
AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.AlanHK ought to be getting tired of karma fortunes by now.
 
AlanHK's Avatar
 
Posts: 668
Karma: 929286
Join Date: Apr 2014
Device: PW-3, iPad, Android phone
Quote:
Originally Posted by eschwartz View Post
Sigil automatically flattens that and restructures the file tree.
Usually it's Calibre you have to be wary of, renaming and moving stuff around.

If folders are legal in an epub, Sigil should let them be, and let us work with them.
AlanHK is offline   Reply With Quote
Advert
Old 05-21-2015, 03:42 PM   #6
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,421
Karma: 85397180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
calibre only renames and moves around library files. The editor operates on the principle of "I'll do it only if you specifically ask for it" -- a lot more control than Sigil.

Normally it isn't harmful to rearrange the file/folder structure (and calibre editor contains a tool to do the same) so Sigil automatically does so on opening, which can break when files have the same name but are in different folders.
eschwartz is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiple editing of titles And365 Library Management 9 05-10-2014 07:49 PM
editing multiple authors at a time stanlefor Recipes 0 02-13-2014 10:02 AM
editing books kasia Calibre 14 09-02-2011 04:30 AM
<Command Line> Add multiple books in multiple formats himitsu Calibre 8 09-25-2010 11:07 PM
Editing multiple ebook's metadata mjh215 Calibre 3 11-24-2008 12:44 PM


All times are GMT -4. The time now is 10:26 PM.


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