Re: Can we have more maths in calc()?

On 4/7/14 9:41 PM, Zack Weinberg wrote:
> OK, I can see why you would be unenthusiastic about min and max on
> <length> particularly when percentages get involved, but note that the
> use case I described only requires them for <number>.  Can the same
> mess still creep in if they are restricted to <number>?

I would think so.  Given real numbers A, B:

   min(Apx, Bpx) == min(A,B)*1px
   min(A%, B%) == min(A, B)*1%

and similar for max.  So given min/max on <number> you can produce all 
the same behavior that you can produce with min/max on lengths.  You 
just have to jump through a tiny (or is it large, since the jump is 
easy?) hoop.

-Boris

Received on Tuesday, 8 April 2014 01:48:38 UTC