Re: [css3-2d-transforms][css3-images] <position> grammar is duplicated or points to the wrong spec

On Tue, Jan 24, 2012 at 11:30 AM, Brian Manthos <brianman@microsoft.com> wrote:
> Tab:
>> Your proposal for <complex-anchor> appears to roughly the same as what
>> I'm suggesting, except that it additionally allows a bare
>> "background-position: 50% + 5px;", and it still makes
>
> My proposal doesn't say that.  That's one incarnation you *could* specify in the (new) 4th and 5th clauses.
>
> Some simple variations could be...
>        Background-position: complex-anchor(50% + 5px);
>        Background-position: (50% + 5px);
>
>
> Brian:
>> The following approach is significantly better:
>> 1. Backgrounds: Introduce <complex-anchor>
>>       <complex-anchor> = <percentage> [+ | -] <length>
>> 2. Backgrounds: Introduce 4th (and maybe 5th) clause(s) to <bg-position> that show when <complex-anchor>
>> can be used.  Note that it's probably desirable to only > support this in background-position not anywhere else
>> that <position> is now being used.
>> 3. Backgrounds: Define how <complex-anchor> behaves when used within a background-position value
>> 4. Values: Describe how "calc(<complex-anchor>)" resolves to "<complex-anchor>" when found within
>> background-position values
>> Result:  Backgrounds module remains the definitive authority on how background-position behaves and there is no ambiguity.
>
> Tab:
>> "background-position: 50%" and "background-position: calc(50%)"
>> resolve to different values (I think).
>
> If you only did steps 1-3, yes.  If you also do step 4, no.

Just for clarity, here's your proposal again:

1. Backgrounds: Introduce <complex-anchor>
       <complex-anchor> = <percentage> [+ | -] <length>
2. Backgrounds: Introduce 4th (and maybe 5th) clause(s) to
<bg-position> that show when <complex-anchor> can be used.  Note that
it's probably desirable to only support this in background-position
not anywhere else that <position> is now being used.
3. Backgrounds: Define how <complex-anchor> behaves when used within a
background-position value
4. Values: Describe how "calc(<complex-anchor>)" resolves to
"<complex-anchor>" when found within background-position values

My proposal is, more or less, to do only steps 3 and 4.  The rest
seems unnecessary.

~TJ

Received on Tuesday, 24 January 2012 19:37:49 UTC