![]() |
#1 |
Connoisseur
![]() Posts: 79
Karma: 10
Join Date: Apr 2014
Device: galaxy 2
|
Assigning custom style sheets to a particular book
Is there a way to create a style sheet for a book and permanently assign it to that book such that the custom styles load automatically when the book loads?
|
![]() |
![]() |
![]() |
#2 |
creator of calibre
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 45,345
Karma: 27182818
Join Date: Oct 2006
Location: Mumbai, India
Device: Various
|
Open it in the editor and copy paste your stylesheet at the bottom of its existing stylesheet.
|
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Resident Curmudgeon
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 79,745
Karma: 145864619
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
How do you know your custom style sheet will actually work with that book? Are you sure all the class names your sheet is using will exist in the style sheet of this book?
|
![]() |
![]() |
![]() |
#4 | |
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31,047
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
Quote:
Why do people assume that a Their Generic stylesheet will line up? The only case would be for / applied to bare tags: <p>,<div>,<h3>... In addition to replacement as suggested by Kovid. You can ADD a second (or more) stylesheet to the book and LINK them to selected files, using the editors right-click in the filelist, menu. Remember that any sheet not linked at that time, will be UN-linked from those files. |
|
![]() |
![]() |
![]() |
#5 |
Resident Curmudgeon
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 79,745
Karma: 145864619
Join Date: Nov 2006
Location: Roslindale, Massachusetts
Device: Kobo Libra 2, Kobo Aura H2O, PRS-650, PRS-T1, nook STR, PW3
|
What you are best to do is to load the eBook into the editor and remove all unused CSS. The have a look at the CSS and make changes as you want.
|
![]() |
![]() |
Advert | |
|
![]() |
#6 |
Connoisseur
![]() Posts: 79
Karma: 10
Join Date: Apr 2014
Device: galaxy 2
|
This worked well thank you. However, as someone mentioned above, you have to remember to LINK the style sheet to the all the html files by selecting them and right clicking.
|
![]() |
![]() |
![]() |
#7 | |
Connoisseur
![]() Posts: 79
Karma: 10
Join Date: Apr 2014
Device: galaxy 2
|
Quote:
|
|
![]() |
![]() |
![]() |
#8 |
Well trained by Cats
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 31,047
Karma: 60358908
Join Date: Aug 2009
Location: The Central Coast of California
Device: Kobo Libra2,Kobo Aura2v1, K4NT(Fixed: New Bat.), Galaxy Tab A
|
|
![]() |
![]() |
![]() |
#9 |
Connoisseur
![]() Posts: 79
Karma: 10
Join Date: Apr 2014
Device: galaxy 2
|
I build websites so style sheets I have been familiar with for a while. It's a drag when you start out, but it gets fun when you realize how much you can do.
|
![]() |
![]() |
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Q2: (Bug?) Import Style sheets | phossler | Editor | 20 | 01-07-2014 05:00 PM |
Style Sheets in Calibre | jerrywat | Conversion | 1 | 09-07-2012 01:35 PM |
SVG style sheets in EPUBs | Chang | ePub | 11 | 02-24-2012 09:41 AM |
style sheets | bramwell1922 | Sigil | 11 | 11-16-2011 03:05 PM |
Sigil Style Sheets | crutledge | Sigil | 3 | 10-06-2010 08:48 AM |