Re: [css3-values] Interaction of vw/vh and scrollbars

On 12/4/12 12:40 PM, Sylvain Galineau wrote:
> Precisely. And so is there a compelling reasons for the spec to define which type of scrollbars
> cause which units to adjust?

I don't think the spec would have to do that.  If we wanted the 
auto-adjusting behavior (which is not obvious), we could just define 
vw/vh to be in terms of the ICB.  Except that happens to be what 
http://dev.w3.org/csswg/css3-values/#viewport-relative-lengths says 
already, except it also talks about "viewport" which is not quite the 
same thing, the claims of 
http://www.w3.org/TR/CSS21/visudet.html#containing-block-details 
notwithstanding...

I do think it's a bit weird that if I have a position:fixed element with 
no border/padding/margin, then setting "width: 20vh; right: 0" and 
"width: 20vh; left: 80vh" don't have the same behavior when there's a 
vertical scrollbar.  But this keeps coming back to what the use cases 
for vh/vw are.

-Boris

Received on Tuesday, 4 December 2012 17:46:08 UTC