Re: [csswg-drafts] [css-ruby] Does line-height have an effect on any of the ruby boxes? (#4979)

The CSS Working Group just discussed `line height on ruby boxes`, and agreed to the following:

* `RESOLVED: line-height on the ruby container doesn't affect the boxes inside`
* `RESOLVED: ruby containers, ruby bases and ruby base containers act like inline boxes, we'll use line-height as an example and call out exceptions in the spec`
* `RESOLVED: line-height doesn't apply to annotations or annotation containers`

<details><summary>The full IRC log of that discussion</summary>
&lt;emilio> topic: line height on ruby boxes<br>
&lt;emilio> github: https://github.com/w3c/csswg-drafts/issues/4979<br>
&lt;emilio> florian: spec should say whether line-height applies to the inside of the ruby when applied to the ruby container box<br>
&lt;emilio> florian: and whether it applies to the inside ruby boxes<br>
&lt;fantasai> sgtm<br>
&lt;emilio> florian: I think we should define it to _not_ do anything on those<br>
&lt;emilio> florian: seems to be what FF does<br>
&lt;emilio> florian: and I don't think there's a strong use case for it<br>
&lt;emilio> xidorn: I'm slightly surprised<br>
&lt;emilio> xidorn: I think in FF if you apply the line-height to the ruby base it would apply<br>
&lt;emilio> florian: may have mistested<br>
&lt;emilio> florian: do we agree that line-height on the ruby container does nothing to its inside?<br>
&lt;emilio> fantasai: so it doesn't affect the contents but affects the line, right?<br>
&lt;emilio> florian: yes<br>
&lt;emilio> fantasai: I think anything else would be weird<br>
&lt;dbaron> I think this all sounds fine.<br>
&lt;emilio> RESOLVED: line-height on the ruby container doesn't affect the boxes inside<br>
&lt;emilio> florian: now about ruby-base<br>
&lt;emilio> florian: I think there's two things that are reasonable and one that doesn't<br>
&lt;emilio> florian: does nothing would be ok<br>
&lt;emilio> florian: affects the line is ok<br>
&lt;emilio> xidorn: I think in FF it only applies to the line if you set it on the base and container<br>
&lt;emilio> florian: that seems fine<br>
&lt;emilio> astearns: can we test this and confirm?<br>
&lt;emilio> fantasai: there's a first question which is, does it have an effect on ruby annotations / ruby annotation containers?<br>
&lt;fantasai> s/first/another/<br>
&lt;emilio> florian: just tested above and setting line-height on the ruby base does affect the line<br>
&lt;emilio> myles: doesn't this resolution cause the height to double up?<br>
&lt;emilio> xidorn: it wouldn't it's just as if you'd set it on a span in block layout<br>
&lt;emilio> fantasai: I think making them behave like inlines to the extent possible is reasonable<br>
&lt;emilio> myles: line-height on a span is not the same as doing it in the block<br>
&lt;emilio> florian: yeah, this needs phrasing on the spec to match what inlines do<br>
&lt;myles> s/line-height on a span is not the same as doing it in the block/using the maximum value of two nested elements is not exactly the same as how &lt;span> interact with line-height/<br>
&lt;emilio> astearns: is there any other property that we should include in the resolution?<br>
&lt;emilio> fantasai: we shouldn't have a list of properties, we should say that it should behave like inline boxes<br>
&lt;emilio> koji: agree, we should say that ruby boxes are the same as inline boxes, except for some behavior changes. Why do we need to confirm each property separately?<br>
&lt;emilio> florian: the spec was a bit vague in the past, so want to confirm incrementally<br>
&lt;emilio> florian: we can resolve that and save some time<br>
&lt;emilio> fantasai: I think there's value to go through the list, we don't have consensus on how vertical-align behaves and such<br>
&lt;emilio> fantasai: though the spec should be worded generically<br>
&lt;emilio> koji: so we shouldn't put each property that behaves the same in the spec, right?<br>
&lt;emilio> fantasai: right, though we might put some as examples, but we shouldn't build an exclusive list<br>
&lt;emilio> RESOLVED: ruby containers, ruby bases and ruby base containers act like inline boxes, we'll use line-height as an example and call out exceptions in the spec<br>
&lt;emilio> florian: two follow-up questions: for ruby annotations, and their containers, does line-height do anything?<br>
&lt;emilio> florian: I think the answer is no<br>
&lt;emilio> florian: because they're kind of like rows, and line-height doesn't affect layout<br>
&lt;emilio> fantasai: it does, they take up spaces no the line<br>
&lt;emilio> florian: they need to align so there is some kind of line box happening<br>
&lt;emilio> s/florian/fantasai<br>
&lt;emilio> fantasai: so I think we should say it should not apply because you can set line-height and such on the annotation container<br>
&lt;emilio> fantasai: because it's anonymous so the font-size is inherited<br>
&lt;emilio> fantasai: so I think we should say it doesn't apply<br>
&lt;emilio> florian: I disagree with one intermediate point but the conclusion remains true<br>
&lt;emilio> florian: anybody thinks that line-height should apply to annotations / annotation-container?<br>
&lt;emilio> xidorn: I don't see how it can be useful<br>
&lt;emilio> koji: did you test browsers?<br>
&lt;emilio> florian: yes. For chrome is harder to test because the model isn't that close, I don't think it has annotation containers in their current implementation<br>
&lt;emilio> florian: but yes, in FF line-height doesn't do anything<br>
&lt;emilio> koji: ok<br>
&lt;emilio> RESOLVED: line-height doesn't apply to annotations or annotation containers<br>
&lt;fantasai> Here's Xidorn's issue : https://lists.w3.org/Archives/Public/www-style/2015Mar/0181.html<br>
</details>


-- 
GitHub Notification of comment by css-meeting-bot
Please view or discuss this issue at https://github.com/w3c/csswg-drafts/issues/4979#issuecomment-624648356 using your GitHub account

Received on Wednesday, 6 May 2020 13:26:47 UTC