Re: [css-shapes] how to position <basic-shape>s

On Wed, Oct 9, 2013 at 2:22 PM, Lev Solntsev <greli@mail.ru> wrote:
> While compatibility is good thing to concern, background-position syntax
> gives more possibilities. An element can be positioned from the bottom
> right corner. Also it's good for i18n—positioning from the right edge
> is an usual case in RTL-manner styling.

You can do that without the <position> syntax - just use calc().  20px
from the right edge is "calc(100% - 20px)".  The <position> syntax
makes this more convenient/readable, but the only difference in
ability is the functionality of percentages.

> And why did you decided that one expects the bottom right corner and
> not centering? I think, 50%-ish is a good way for centering in CSS.

Either is possibly what the author intended, which is why we should
allow both.  Alan's proposal does that.

For example, if you're doing something clever from script with
clipping/masking/shaping/etc, it's probably easier to use the
SVG-inspired syntax.  If using them in static CSS, the CSS-inspired
syntax is probably easier.

~TJ

Received on Wednesday, 9 October 2013 21:39:14 UTC