Re: Styling HTML5 elements

On Oct 15, 2009, at 9:34 PM, Brad Kemper wrote:

> The downside is that you don't get the subtle color blends or the  
> horizon line when it is empty. I'd rather do this:
> clip: rect( calc( 30px, 130px, 130px, 0px );
> apply-effect: clip, background-image(0);
> To clip just the single background-image that acts as the guage.

Sorry, I meant to remove calc() to make the basics of this more  
obvious, but I left a little behind in that example (and also  
miscalculated the number). I should have done it like this:

clip: rect(34px, 130px, 130px, 0px );
apply-effect: clip, background-image(0);

Thus the 130px diameter, zeroth layer background is clipped at 34px  
from the top, and in practice would perhaps be replaced by: 'calc 
((1.00-.74)*130)' to get a "74% full" indicator, or by your even more  
specific to the example calculation: 'calc( attr("value",integer) /  
attr("max",integer) * 130px )'.

Received on Friday, 16 October 2009 15:46:18 UTC