22.12.2013 Views

W3C CSS2 Cascading Style Sheets, level 2 - instructional media + ...

W3C CSS2 Cascading Style Sheets, level 2 - instructional media + ...

W3C CSS2 Cascading Style Sheets, level 2 - instructional media + ...

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Start of outer contents.<br />

Inner contents.<br />

End of outer contents.<br />

End of body contents.<br />

<br />

<br />

<br />

In this document, we assume the following rules:<br />

BODY { display: block; line-height: 200%;<br />

width: 400px; height: 400px }<br />

P { display: block }<br />

SPAN { display: inline }<br />

The final positions of boxes generated by the outer and inner elements vary in<br />

each example. In each illustration, the numbers to the left of the illustration indicate<br />

the normal flow [p. 105] position of the double-spaced (for clarity) lines.<br />

(Note: the illustrations use different horizontal and vertical scales.)<br />

9.8.1 Normal flow<br />

Consider the following CSS declarations for outer and inner that don’t alter the<br />

normal flow [p. 105] of boxes:<br />

#outer { color: red }<br />

#inner { color: blue }<br />

The P element contains all inline content: anonymous inline text [p. 98] and<br />

two SPAN element. Therefore, all of the content will be laid out in an inline<br />

formatting context, within a containing block established by the P element,<br />

producing something like:<br />

116

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!