View Single Post
Old 03-24-2012, 10:40 AM   #6
dwig
Guru
dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.dwig ought to be getting tired of karma fortunes by now.
 
dwig's Avatar
 
Posts: 963
Karma: 1382338
Join Date: Dec 2004
Location: Paradise (Key West, FL)
Device: Current:Dell Venue 8 Pro, Kindle 3/WiFi - Retired:Clie UX50, T415, ...
Quote:
Originally Posted by Toxaris View Post
Personally I would use:
Code:
.center {
text-align: center
margin-top: 1.2em;
margin-bottom: 1.2em;
}
This will adjust the blank line with the font size to keep it in proportion.
I agree with using em units, particularly since such scene breaks occur in the general flow of the text and not as "headings" at the top of a screen.

While a style name can be any string of characters, I would suggest using a more descriptive name like "scene" or "scenebreak" instead of "center" for this. That way you can use "center" for a simpler centering style without the wide top and bottom margins. It makes reading the code at a later date much easier.

My personal approach is to style the <p> with the asterisks, or more often an image, using my .heading style and then style the first <p> in the new scene using my .scene style. This allows me to omit the asterisk line when only a blank gap is desired without having to add a unique style for that book. Using the same style names in all (or most) of my books makes creation and editing much easier.

Code:
.heading {
  text-indent: 0em;
  margin-top: 1em;
  margin-bottom: 0em;
  text-align: center;
  }
.section {
  text-indent: 1em;
  margin-top: 1em;
  }
dwig is offline   Reply With Quote