Register Guidelines E-Books Today's Posts Search

Go Back   MobileRead Forums > E-Book Software > Sigil

Notices

Reply
 
Thread Tools Search this Thread
Old 11-21-2012, 09:45 PM   #1
michaelbr
Connoisseur
michaelbr began at the beginning.
 
michaelbr's Avatar
 
Posts: 77
Karma: 10
Join Date: Aug 2010
Location: Murcia/Spain
Device: Android 12
master css for every chapter

Is there anyway to setup a master css file/template for every single html page/chapter you create? If so how can I do it?
michaelbr is offline   Reply With Quote
Old 11-21-2012, 11:25 PM   #2
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,785
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 michaelbr View Post
Is there anyway to setup a master css file/template for every single html page/chapter you create? If so how can I do it?
Please clairfy:
1 CSS for all chapters?
or
a separate CSS for each chapter.

(using Sigil 6):
for the single CSS:
Create or add the CSS (use File menu)
once in place, Select 1 or more HTML files Right click : Link stylesheets: TICK the sheets to link (could be more than 1): OK
theducks is offline   Reply With Quote
Old 11-22-2012, 07:24 AM   #3
mrmikel
Color me gone
mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.mrmikel ought to be getting tired of karma fortunes by now.
 
Posts: 2,089
Karma: 1445295
Join Date: Apr 2008
Location: Central Oregon Coast
Device: PRS-300
This action puts a link statement for that particular stylesheet in the <head> of each section of your book.

This may not always be desirable, for things such as indents. Indents are great in text, but not so great in an index or captions. So be careful what you put in your master and consider using a modified master for areas where you don't want indents or something else that is not universally applicable.

The link action described above is a one time thing, so you can take out the link if you don't want it and use the same action to link to a different stylesheet that suits your needs for a particular section. It works very easily doing this.
mrmikel is offline   Reply With Quote
Old 11-22-2012, 10:26 PM   #4
michaelbr
Connoisseur
michaelbr began at the beginning.
 
michaelbr's Avatar
 
Posts: 77
Karma: 10
Join Date: Aug 2010
Location: Murcia/Spain
Device: Android 12
Quote:
Originally Posted by theducks View Post
Please clairfy:
1 CSS for all chapters?
or
a separate CSS for each chapter.

(using Sigil 6):
for the single CSS:
Create or add the CSS (use File menu)
once in place, Select 1 or more HTML files Right click : Link stylesheets: TICK the sheets to link (could be more than 1): OK
Thanks theducks for your prompt reply and sorry for the wording, what I meant is for all chapters and thanks for the tip to link one css to several html files, I didn't know this trick. For consistency purpose, it would be nice if there's a way to have only 1 master css which will be inherited to all other html files, and when we need to change some chapters, we'll change just those chapters. I guess it's not the limitation of Sigil but CSS, right?
michaelbr is offline   Reply With Quote
Old 11-22-2012, 10:33 PM   #5
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,785
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 michaelbr View Post
Thanks theducks for your prompt reply and sorry for the wording, what I meant is for all chapters and thanks for the tip to link one css to several html files, I didn't know this trick. For consistency purpose, it would be nice if there's a way to have only 1 master css which will be inherited to all other html files, and when we need to change some chapters, we'll change just those chapters. I guess it's not the limitation of Sigil but CSS, right?
Once the Link has been made, it is there until you edit it out of the HTML.
a typical book Only has 1 (shared CSS, but you need to set the link into the file.
You are not limited to a Single CSS for a single HTML file either. If one file has a special, complex style, I leave those in a seperate CSS and only link that to the file that nees it, thus saving the need to parse a BIG css for every file.
theducks is offline   Reply With Quote
Old 11-23-2012, 08:31 AM   #6
mncowboy
Wanderer
mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.mncowboy ought to be getting tired of karma fortunes by now.
 
mncowboy's Avatar
 
Posts: 106
Karma: 472218
Join Date: Jan 2011
Device: Kindle 3, PaperWhite 2
If your master document is one html file that you bring into Sigil, add the link to the css file. Then when you split the file up in Sigil, it will automatically include everything in the head section for each of the split files.
mncowboy is offline   Reply With Quote
Old 11-23-2012, 08:39 PM   #7
michaelbr
Connoisseur
michaelbr began at the beginning.
 
michaelbr's Avatar
 
Posts: 77
Karma: 10
Join Date: Aug 2010
Location: Murcia/Spain
Device: Android 12
Quote:
Originally Posted by theducks View Post
Once the Link has been made, it is there until you edit it out of the HTML.
a typical book Only has 1 (shared CSS, but you need to set the link into the file.
You are not limited to a Single CSS for a single HTML file either. If one file has a special, complex style, I leave those in a seperate CSS and only link that to the file that nees it, thus saving the need to parse a BIG css for every file.
Thanks theducks, good point, I haven't thought this way, I'll use your suggestions in the future, I'm glad I've asked this question so I won't make this mistake further down the road when I have many docs created.

Quote:
Originally Posted by mncowboy View Post
If your master document is one html file that you bring into Sigil, add the link to the css file. Then when you split the file up in Sigil, it will automatically include everything in the head section for each of the split files.
Thanks mncowboy for this tip, I'll combine your tip with theducks in the future to convert several Word document to epub.
michaelbr is offline   Reply With Quote
Reply


Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
What are SGF Chapter Marker and Chapter Break? webphone Sigil 1 05-25-2011 02:43 PM
Adding new chapter, what about CSS link? spaze Sigil 3 02-24-2011 05:35 AM
css pseudo elements and adjacent combinators in extra css? ldolse Calibre 2 12-21-2010 05:09 PM
CSS wacky p indent post-chapter split? Hitch Sigil 0 06-17-2010 08:59 PM
CSS & regex for chapter titles hpstricker Calibre 3 07-17-2008 10:13 AM


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


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