View Single Post
Old 11-11-2012, 03:14 PM   #10
theducks
Grand Sorcerer
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: 15,260
Karma: 6020309
Join Date: Aug 2009
Location: (The original) Silicon Valley, USA
Device: Galaxy Tab 2, Astak Pocket Pro, K4NT
Quote:
Originally Posted by Thasaidon View Post
Thanks Barb-B, I am familiar with and do use Sigil but in this case I used Tag Stripper to strip a HTML file to its bare bones.

I thought Calibre was not behaving as described bu it was just ignorance about how CSS files worked on my part. Unfortunately until I retire next year I have only limited time to spend acquiring such knowledge.
CSS is fairly easy, when you think of it as moving all that long (repetitive) styling to a common place (the stylesheet) and using a shortname instead
The green, is my explanation and not to be included in a CSS as is.
Different calibre numbers may assigned for each conversion AND you can still use your own names in edits. Use a name (selector) i a document, then it should be in some linked CSS.

Code:
Make the first paragraph (used as a Sub title) after any H2: italic
h2 + p {
	font-style: italic;
	}
The standard document (body) style. You could change the name to body if there were no bony variants needed
.calibre {
    display: block;
    font-size: 1.2em;
    margin-bottom: 0;
    margin-left: 2pt;
    margin-right: 16pt;
    margin-top: 0;
    padding-left: 0;
    padding-right: 0;
    page-break-before: always
    }
The standard NON-indented Paragraph style
.calibre2 {
    display: block;
    margin-bottom: 0.5em;
    margin-left: 0;
    margin-right: 0;
    margin-top: 0.5em;
    text-align: justify;
    text-indent: 0
    }
The standard indented Paragraph style
.calibre3 {
    display: block;
    margin-bottom: 0.5em;
    margin-left: 0;
    margin-right: 0;
    margin-top: 0.5em;
    text-align: justify;
    text-indent: 2em
    }

The advantage of this, 1 change in a CSS fixes all the usage
theducks is offline   Reply With Quote