Style Sheet Capabilities

We've been alluding to the capabilities of style sheets for the last three pages, but short of the first example, we haven't talked exactly about how style sheets extend HTML. This section of the chapter will spell out the capabilities of style sheets.

While we call the different style sheet elements 'properties' we don't use them in exactly the same way we use properties of objects. In our example, we set the BODY text properties like this:

BODY   {font-family: Times;
   font-size: 125;
   font-weight: bold; 
   color: red }

As we'll see later in this chapter when we talk about the style object, this is clearly a different way of doing things than we use for objects. With objects we refer to a property by appending a period and the property name to the name of the object instance, like this:

MyTextObject.fontFamily = "Times"
MyTextObject.fontSize = 48

Although it's a semantic difference and not important for understanding the capabilities of style sheets we should keep this in mind while we learn about the different style properties that we can use.