Skip to content

Commit

Permalink
Make line height calculation quirk aware of writing modes
Browse files Browse the repository at this point in the history
This appears to match WebKit and Chromium.

Part of #5.
  • Loading branch information
zcorpan committed Jul 6, 2016
1 parent 0e348be commit 551d9ba
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 5 deletions.
6 changes: 4 additions & 2 deletions Overview.bs
Original file line number Diff line number Diff line change
Expand Up @@ -311,8 +311,10 @@ box had a 'line-height' of zero.

<ul>

<li><p>The 'border-right-width', 'border-left-width', 'padding-right' and 'padding-left' properties
have a <a>used value</a> of zero.
<li><p>The 'border-top-width', 'border-bottom-width', 'padding-top' and 'padding-bottom' properties
have a <a>used value</a> of zero and the box has a <a>vertical writing mode</a>, or the
'border-right-width', 'border-left-width', 'padding-right' and 'padding-left' properties have a
<a>used value</a> of zero and the box has a <a>horizontal writing mode</a>.

<!-- This matches WebKit. Presto and IE9 don't have this [Presto has now implemented this
(CORE-19183)]. Gecko has this rule for all margins, paddings and borders. -->
Expand Down
6 changes: 3 additions & 3 deletions Overview.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
<p data-fill-with="logo"><a class="logo" href="https://whatwg.org/"> <img alt="WHATWG" height="100" src="https://resources.whatwg.org/logo.svg"> </a> </p>
<hgroup>
<h1 class="p-name no-ref" id="title">Quirks Mode</h1>
<h2 class="no-num no-toc no-ref heading settled" id="subtitle"><span class="content">Living Standard — Last Updated <time class="dt-updated" datetime="2016-06-30">30 June 2016</time></span></h2>
<h2 class="no-num no-toc no-ref heading settled" id="subtitle"><span class="content">Living Standard — Last Updated <time class="dt-updated" datetime="2016-07-06">6 July 2016</time></span></h2>
</hgroup>
<div data-fill-with="spec-metadata">
<dl>
Expand Down Expand Up @@ -267,8 +267,8 @@ <h3 class="heading settled" data-algorithm="The line height calculation quirk" d
box had a <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css2/visudet.html#propdef-line-height">line-height</a> of zero. </p>
<ul>
<li>
<p>The <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css-backgrounds-3/#border-right-width">border-right-width</a>, <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css-backgrounds-3/#border-left-width">border-left-width</a>, <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css2/box.html#propdef-padding-right">padding-right</a> and <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css2/box.html#propdef-padding-left">padding-left</a> properties
have a <a data-link-type="dfn" href="https://drafts.csswg.org/css-cascade-4/#used-value">used value</a> of zero. </p>
<p>The <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css-backgrounds-3/#border-top-width">border-top-width</a>, <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css-backgrounds-3/#border-bottom-width">border-bottom-width</a>, <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css2/box.html#propdef-padding-top">padding-top</a> and <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css2/box.html#propdef-padding-bottom">padding-bottom</a> properties
have a <a data-link-type="dfn" href="https://drafts.csswg.org/css-cascade-4/#used-value">used value</a> of zero and the box has a <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-3/#vertical-writing-mode">vertical writing mode</a>, or the <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css-backgrounds-3/#border-right-width">border-right-width</a>, <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css-backgrounds-3/#border-left-width">border-left-width</a>, <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css2/box.html#propdef-padding-right">padding-right</a> and <a class="property" data-link-type="propdesc" href="https://drafts.csswg.org/css2/box.html#propdef-padding-left">padding-left</a> properties have a <a data-link-type="dfn" href="https://drafts.csswg.org/css-cascade-4/#used-value">used value</a> of zero and the box has a <a data-link-type="dfn" href="https://drafts.csswg.org/css-writing-modes-3/#horizontal-writing-mode">horizontal writing mode</a>. </p>
<li>
<p>It either contains no text or it contains only collapsed whitespace. </p>
</ul>
Expand Down

0 comments on commit 551d9ba

Please sign in to comment.