Re: [css3-page] Page-margin boxes layout

Simon Sapin <simon.sapin@kozea.fr> wrote on 2012/11/13 2:54:12
> Le 11/11/2012 20:33, MURAKAMI Shinyu a écrit :
> > The large difference is that the existing spec has the rule “The sum
> > of the outer widths of the three boxes is equal to max box width.”
> 
> Ok, keeping that behavior sounds reasonable. Especially in the default 
> case where all three widths are auto.
> 
> 
> > […] in the following rules:
> > * ... the used width for A and C is the respective ‘max-content’.
> > * ... the used width for B is ‘max-content’.
> > and the rule
> > * ... the used width is min(max-content, max(min-content, available)),
> > will be
> >    the used width is max(min-content, available) ,
> 
> I’m not sure that exact set of changes covers all cases, but I think I 
> understand the general intent and I’ll update the algorithm in that 
> direction.

Thanks.

> 
> 
> > unless ‘width: fit-content’ is specified explicitly.
> >
> > We have not implemented yet the ‘width: fit-content’ for margin boxes
> > but I think it will be useful.
> 
> The definition of fit-content is:
> min(max-content, max(min-content, fill-available))
> 
> If we take that literally, any of the three box could (with a big enough 
> max-content) occupy the whole containing block, without regard of the 
> amount of content in the other margin boxes that share the same 
> containing block. So I think we would have to specialize the definition 
> of fit-content.
> 
> Also, things can get complicated when the three boxes mix 'auto', 
> 'fit-content' or absolute lengths for 'width'…

My thought was that the rule
   * ... the used width is min(max-content, max(min-content, available)),
was equal to the fit-content definition if we use this 'available' width as 
the 'fill-available' width. However, I admit that was not good idea,
I don't want to make things complicated, and now I think we need not to
define specialized fit-content and fill-available for margin boxes.

--
Shinyu Murakami
Antenna House

Received on Wednesday, 14 November 2012 18:48:25 UTC