Re: [Bulk] Re: WebKit now supports CSS Variables

> So is the question: why do you need exactly variables? Who and when is 
> supposed to mutate them?

I suppose the following situation :

    @variables { currentColor: #000000; }
    div.myDiv1 { background: var(currentColor); }
    div.myDiv2 { color: var(currentColor); }
    div.myDiv3 {
        border: 3px outset #000000;
        border-color: var(currentColor);
    }

==> setCSSVariableValue('currentColor', "#111111");

Instead of a long and complex way that's find all rules that must be updated 
by iterating stylesheets[i].rules[j]

Am I giving you a sufficient answer ?

Fremy

__________________

BTW, constants can't exist in CSS because we can enable/disable stylesheets 
and that can change the value of a variable.
So, it a variable can change of value, this is not a constant. 

Received on Wednesday, 25 June 2008 08:35:54 UTC