11<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
22<html lang="en">
3- <!-- $Id: visudet.src,v 2.103 2005-04-12 14:02:15 bbos Exp $ -->
3+ <!-- $Id: visudet.src,v 2.104 2005-04-25 18:20:48 bbos Exp $ -->
44<head>
55<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
66<title>Visual formatting model details</title>
@@ -28,11 +28,14 @@ is defined as follows:</p>
2828
2929<ol>
3030<li>The containing block in which the <a href="conform.html#root">root
31- element</a> lives is the <a href="visuren.html#viewport">viewport</a>
31+ element</a> lives is a rectangle with the dimensions of the <a
32+ href="visuren.html#viewport">viewport</a>, anchored at the canvas
33+ origin
3234for continuous media, and the page area for paged media. This
3335containing block is called the <dfn><span class="index-def"
3436title="initial containing block|containing block::initial">initial
35- containing block</span></dfn>.
37+ containing block</span></dfn>. The 'direction' property of the initial
38+ containing block is the same as for the root element.
3639</li>
3740<li>For other elements, if the element's position is 'relative' or 'static',
3841the containing block is formed by the content edge of the nearest
@@ -350,7 +353,8 @@ all of the above have a computed value other than 'auto', the values
350353are said to be "over-constrained" and one of the used values will
351354have to be different from its computed value. If the <span
352355class="propinst-direction">'direction'</span>
353- property has the value 'ltr', the specified value of <span
356+ property of the containing block has the value 'ltr', the specified
357+ value of <span
354358class="propinst-margin-right">'margin-right'</span> is ignored and the
355359value is calculated so as to make the equality true. If the value of
356360<span class="propinst-direction">'direction'</span> is 'rtl', this
@@ -454,7 +458,8 @@ elements is:</p>
454458
455459<p>If all three of 'left', 'width', and 'right' are 'auto': First set
456460any 'auto' values for 'margin-left' and 'margin-right' to 0. Then, if
457- 'direction' is 'ltr' set 'left' to the <a
461+ the 'direction' property of the containing block is 'ltr' set 'left'
462+ to the <a
458463href="#static-position">static position</a> and apply rule number
459464three below; otherwise, set 'right' to the <a
460465href="#static-position">static position</a> and apply rule number
@@ -464,11 +469,13 @@ one below.</p>
464469'margin-right' are 'auto', solve the
465470equation under the extra constraint that the two margins get equal
466471values, unless this would make them negative, in which case when
467- direction is 'ltr' ('rtl'), set 'margin-left' ('margin-right') to zero
472+ direction of the containing block is 'ltr' ('rtl'), set 'margin-left'
473+ ('margin-right') to zero
468474and solve for 'margin-right' ('margin-left'). If one of
469475'margin-left' or 'margin-right' is 'auto', solve the equation for that
470476value. If the values are over-constrained, ignore the value for 'left'
471- (in case 'direction' is 'rtl') or 'right' (in case 'direction' is
477+ (in case the 'direction' property of the containing block is 'rtl') or
478+ 'right' (in case 'direction' is
472479'ltr') and solve for that value.</p>
473480
474481<p>Otherwise, set 'auto' values for 'margin-left' and 'margin-right'
@@ -480,7 +487,8 @@ to 0, and pick the one of the following six rules that applies.</p>
480487width is shrink-to-fit. Then solve for 'left'</li>
481488
482489<li>'left' and 'right' are 'auto' and 'width' is not 'auto', then if
483- 'direction' is 'ltr' set 'left' to the <a
490+ the 'direction' property of the containing block is 'ltr' set 'left'
491+ to the <a
484492href="#static-position">static position</a>, otherwise set 'right'
485493to the <a href="#static-position">static position</a>. Then solve
486494for 'left' (if 'direction is 'rtl') or 'right' (if 'direction' is
@@ -525,7 +533,8 @@ elements</a>.
525533</li>
526534<li>If both <span class="propinst-left">'left'</span> and <span
527535class="propinst-right">'right'</span> have the value 'auto', then if
528- 'direction' is 'ltr', set <span class="propinst-left">'left'</span> to
536+ 'direction' of the containing block is 'ltr', set <span
537+ class="propinst-left">'left'</span> to
529538the static position; else if 'direction' is 'rtl', set <span
530539class="propinst-right">'right'</span> to the static position.
531540</li>
@@ -539,7 +548,8 @@ class="propinst-margin-left">'margin-left'</span> and <span
539548class="propinst-margin-right">'margin-right'</span> are still 'auto',
540549solve the equation under the extra constraint that the two margins
541550must get equal values, unless this would make them negative, in which
542- case when direction is 'ltr' ('rtl'), set <span
551+ case when the direction of the containing block is 'ltr' ('rtl'), set
552+ <span
543553class="propinst-margin-left">'margin-left'</span> (<span
544554class="propinst-margin-right">'margin-right'</span>) to zero and solve
545555for <span class="propinst-margin-right">'margin-right'</span> (<span
@@ -549,8 +559,9 @@ class="propinst-margin-left">'margin-left'</span>).
549559for that value.
550560</li>
551561<li>If at this point the values are over-constrained, ignore the value
552- for either <span class="propinst-left">'left'</span> (in case <span
553- class="propinst-direction">'direction'</span> is 'rtl') or <span
562+ for either <span class="propinst-left">'left'</span> (in case the
563+ <span class="propinst-direction">'direction'</span> property of the
564+ containing block is 'rtl') or <span
554565class="propinst-right">'right'</span> (in case <span
555566class="propinst-direction">'direction'</span> is 'ltr') and solve for
556567that value.
@@ -1243,21 +1254,21 @@ subsequent lines to paint over the borders and text of previous lines.
12431254</p>
12441255<!-- #include src=properties/line-height.srb -->
12451256
1246- <p>If the property is set on a <a
1257+ <p>On a <a
12471258href="visuren.html#block-level">block-level</a>, <span
12481259class="index-inst">table-cell</span>, <span
12491260class="index-inst">table-caption</span> or <span
12501261class="index-inst">inline-block</span> element whose content
12511262is composed of <a href="visuren.html#inline-level">inline-level</a>
1252- elements, it specifies the <em>minimal</em> height of line boxes
1263+ elements, 'line-height' specifies the <em>minimal</em> height of line boxes
12531264within the element. The minimum height consists of a minimum height above
12541265the block's baseline and a minimum depth below it, exactly as if each
12551266line box starts with a <a name="strut">zero-width inline box with the
12561267block's font and line height properties (what T<sub>E</sub>X calls a
12571268"strut").</a>
12581269</p>
1259- <p>If the property is set on an <a
1260- href="visuren.html#inline-level">inline-level</a> element, it
1270+ <p>On an <a
1271+ href="visuren.html#inline-level">inline-level</a> element, 'line-height'
12611272specifies the height that is used in the calculation of the line box
12621273height (except for inline <a
12631274href="conform.html#replaced-element">replaced</a> elements, where the
0 commit comments