I'm looking at tidying up the code on a ePub and find that each (of 80) xhtml file has its own style definitions. So I wanted to start by extracting these and putting them all in the common stylesheet.css file.
Then I found they reuse the same style names with different definitions :
e.g.:
Code:
<style type="text/css">
p.sgc-2 {font-style: italic}
a.sgc-1 {font-weight: bold}
</style>
and
Code:
<style type="text/css">
p.sgc-2 {font-weight: bold}
a.sgc-1 {font-weight: bold}
</style>
All the styles have "sgc" in their name. Anyone know where they come from?
Merging two of these files in Sigil, it doesn't notice the conflict and the sgc-2 bold in the second file is now italic.
Obviously global S&R will just scramble these up. Is there any way short of editing each file individually to rationalise the styles, to e.g.
Code:
p.italic {font-style: italic}
p.bold {font-weight: bold}
which I can then put in the global css?
(I'd rather just use <b> and <i> myself, but that would be too simple.)