@@ -418,7 +418,7 @@ <h3 id=layout-grid-mode-prop><span class=secno>3.1. </span>Grid Mode: the
418418 < tr >
419419 < th > Value:
420420
421- < td > none | block | line
421+ < td > none | baseline | block | line
422422
423423 < tr >
424424 < th > Initial:
@@ -460,6 +460,17 @@ <h3 id=layout-grid-mode-prop><span class=secno>3.1. </span>Grid Mode: the
460460
461461 < dd > Do not align any objects to the grids.
462462
463+ < dt > < dfn id =baseline title ="layout-grid-mode::baseline "> ‘< code
464+ class =css > baseline</ code > ’</ dfn >
465+
466+ < dd > Align baselines to the line grids. <!--
467+ The line in this definition is a line box
468+ with before margin included if it is the first line of a block,
469+ and with after margin if last.
470+ -->
471+ The height is the height of the line box. Increasing heights to fit to
472+ grids is done by increasing the computed height of the line box.
473+
463474 < dt > < dfn id =block title ="layout-grid-mode::block "> ‘< code
464475 class =css > block</ code > ’</ dfn >
465476
@@ -484,12 +495,22 @@ <h3 id=layout-grid-mode-prop><span class=secno>3.1. </span>Grid Mode: the
484495 < p class =issue > Handling margins and borders needs review
485496
486497 < p > When this property is set to anything other than ‘< code
487- class =css > none</ code > ’, the object to align is vertically centered
488- within the grid row. If the computed height is larger than the grid space,
489- then the object is centered within the smallest number of grid rows
490- necessary for the object to fit in. The starting alignment point is moved
491- accordingly. This is illustrated below, where < em > a</ em > represents the
492- numerical ‘< a href ="#layout-grid-line "> < code
498+ class =css > none</ code > ’, the computed height of the object is
499+ increased to the smallest multiple of the grid heights that is equal to or
500+ smaller than the original computed height.
501+
502+ < p > When the value of this property is ‘< code
503+ class =css > baseline</ code > ’, the line box is then moved so that its
504+ baseline is aligned to the next closest grid.
505+
506+ < p > When the value of this property is either ‘< code
507+ class =css > block</ code > ’ or ‘< code
508+ class =css > line</ code > ’, the object is vertically centered within the
509+ grid row. If the computed height is larger than the grid space, then the
510+ object is centered within the smallest number of grid rows necessary for
511+ the object to fit in. The starting alignment point is moved accordingly.
512+ This is illustrated below, where < em > a</ em > represents the numerical
513+ ‘< a href ="#layout-grid-line "> < code
493514 class =property > layout-grid-line</ code > </ a > ’ value, < em > b</ em > and
494515 < em > c</ em > are half the difference between the computed line-heights and
495516 either the layout-grid-line value or twice the value respectively.:
@@ -518,7 +539,8 @@ <h3 id=layout-grid-mode-prop><span class=secno>3.1. </span>Grid Mode: the
518539 baselines to grids rather than center of line boxes if we consider cases
519540 like only a word in a line is large. But how can we align baselines to
520541 grids? Align baselines to center of grids? Lines may not fit within one
521- grid.
542+ grid. Align baselines to grids might work better, but it may not work well
543+ with settings headigns to ‘< code class =css > block</ code > ’.
522544
523545 < div class =example >
524546 < div class =sidefigure > < img alt ="Large text wraps within line grids "
@@ -866,6 +888,9 @@ <h2 class=no-num id=index>Index</h2>
866888 < li > layout-grid-mode, < a href ="#layout-grid-mode "
867889 title =layout-grid-mode > < strong > 3.1.</ strong > </ a >
868890 < ul >
891+ < li > baseline, < a href ="#baseline " title ="layout-grid-mode,
892+ baseline "> < strong > 3.1.</ strong > </ a >
893+
869894 < li > block, < a href ="#block " title ="layout-grid-mode,
870895 block "> < strong > 3.1.</ strong > </ a >
871896
@@ -935,7 +960,7 @@ <h2 class=no-num id=property-index>Property index</h2>
935960 < tr valign =baseline >
936961 < td > < a class =property href ="#layout-grid-mode "> layout-grid-mode</ a >
937962
938- < td > none | block | line
963+ < td > none | baseline | block | line
939964
940965 < td > none
941966
0 commit comments