Re: [css-ruby][css-writing-modes] The writing-mode property on ruby internal boxes

On 07/16/2015 10:38 PM, Xidorn Quan wrote:
>
> According to CSS 2.1 spec, when a property does not apply to an element, this property won't affect the rendering effect of
> the element [1], but the computed value still exists [2]. I guess it means that, the used value does not exist in that case.

Yes, exactly.

> Then I changed my mind. Similar to table cases, we should exclude ruby base container and ruby text container from "Applies
> to" of "writing-mode", but still allow that property to be applied on ruby base box and ruby text box, so their content is
> allowed to be orthogonal to the line (probably with an anonymous inline-block inside instead of making those boxes themselves
> orthogonal).

This probably works. Although I'd lean towards making the ruby text
box and base box handle the writing-mode themselves, similar to how
inline-block can handle writing-mode changes themselves.

> About "ruby-position", I give up my proposed change to make it always force the writing-mode. But we indeed need some change
> to the rule for inter-character (though it is unrelated to my proposal here).
>
> Since the anonymous box generation step happens after style computation stage (as we need to know at least the display type of
> both parent and children anyway), and both <rt> and <rtc> can be an anonymous box, it will need some hack. My idea is:
> Compute the "writing-mode" of an element to "vertical-rl" if
> 1) the display type is "ruby-text" and its parent has "ruby-position: inter-character", or
> 2) the display type is "ruby-text-container" and the element itself has "ruby-position: inter-character".
> Note that, the computed value for ruby-text-container is not applied to the container itself, but for being inherited by its
> non-pseudo children.

I'm okay with this, but I don't quite remember the cyclic computation
problem we were discussing earlier. Does this solve that problem?

~fantasai

Received on Wednesday, 29 July 2015 00:38:20 UTC