Re: [css3-images] rtl/ltr annotation

On Sat, Mar 10, 2012 at 12:16 PM, Tab Atkins Jr. <jackalmage@gmail.com> wrote:
> On Sat, Mar 10, 2012 at 11:57 AM, Andrew Fedoniouk
> <news@terrainformatica.com> wrote:
>> Reference: http://dev.w3.org/csswg/css3-images/#image-notation
>>
>> Am I correct in my assumptions that two cases below are functional equivalents?
>>
>> 1.  el { background: image(a.png ltr, b.png rtl); }
>>
>> 2.  el:dir(ltr) { background: url(a.png); }
>>     el:dir(rtl) { background: url(b.png); }
>>
>> In other words, these ltr/rtl annotators are sensors of what actually?
>
> They aren't sensors at all.  They *declare* the image to be ltr or
> rtl.  Then, if it finds itself in an element with opposite
> directionality, it's flipped in the inline direction.  So no, your two
> cases are definitely not equivalent.
>
> All of this is described pretty clearly in the spec.  The entire
> description is a single short paragraph.

Interesting.
If so then "annotate an image with a directionality" phrase
is misleading.

For me annotation means act of assignment of some attribute.
But not the act of transforming image pixels (flipped as you mentioned).

In any case image transformations (filters of any kind) should be a
subject of some other mechanism I think. There are many other
things that AFAIR were already requested for images.

Something like
background-image-transformation: brightness(0.7) flip-x;
background-image-transformation: flip-y;
background-image-transformation: rotate(90deg);
background-image-transformation: transparent(rgb(255,255,0));
background-image-transformation: shadow(1,1,2px);
etc.

Such filters actually could be a part of the image() thing:

image( a.png flip-x-if(rtl) )
image( b.png flip-x-if(ltr) )
image( c.png rotate-if(ttb,90deg) )
image( d.png brightness(0.7) flip-x-if(rtl) )

etc.

I mean if we've started speaking about image transformations then
we should use use syntax that is extendable.


-- 
Andrew Fedoniouk.

http://terrainformatica.com

Received on Saturday, 10 March 2012 20:54:53 UTC