DSGN53871
WEB DESIGN 1

Inheritance in Cascading Stylesheets

Defined: a property is inherited from the parent.

CSS inheritance can be used by specifically ordering properties. For example, if the font-family for a paragraph is set, then the font-family is inherited by any span elements inside the paragraph.

Only some CSS properties are inherited.

Some properties are are not. Generally, borders and margins are not inherited, nor does it make sense for them to be so.

A pdf illustrating CSS Inheritance is here.



<< Back


Interactive Multimedia ~ School of Applied Engineering and Computing Sciences ~ Sheridan