• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint

The Anatomy of a Style

A style is made up of a tag name (H1, P, etc.) and one or more definitions[1] that determine how the elements marked with that tag should be displayed—perhaps in red, at 12 points, with Lithos Regular.

[1] (The W3C uses fancier words than I do: the tag name is called a selector and the definitions are called declarations.)

Each definition contains a property, a colon, and one or more values. For example, to change the color of text, you use the color property with a value of say, red. The definition would read color: red. The space after the colon is not required. Multiple definitions must be separated by semicolons (Figure 13.3).


PREVIEW

                                                                          

Not a subscriber?

Start A Free Trial


  
  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint