Re: [idea] lighweight inline vector images in CSS and HTML

On Sun, Mar 20, 2016 at 3:16 AM, Henrik Andersson <henke@henke37.cjb.net>
wrote:

> Andrew Fedoniouk skrev:
> > SVG paths are OK in general but they do not support "expandable"
> > images - images that fill given area by not just uniformly scaling but
> > having points anchored not just to left/top but to right/bottom.
> >
> > By achieving "expandability" I've extended original "d-command" syntax
> > a bit:
> > All "absolute" commands (uppercase ones:  MLHVCSQTA) when given
> > negative coordinates use those as offset from right and bottom sides
> > of image box:
> >
> > Consider this style:
> >
> >     section > div {
> >         background-image: url(path:M0,-0 C10,-0,10,0,20,0 L-20,0
> > C-10,0,-10,-0,-0,-0);
> >         background-repeat:no-repeat;
> >         background-size:100% 100%;
> >         fill:gold;
> >         stroke:#444;
> >         stroke-width:0.5px;
> >         width:max-content;
> >         padding:4px 25px;
> >         margin:5px;
> >         outline:1px dashed #aaa;
> >       }
> >
> > It defines expandable "bell-tab" curve. ...
>


> It's valid for a SVG path to extend into the negative coordinate space.
> Giving negative coordinates special treatment would be a bad idea. You'd
> need a different marker.
>

Well, that feature is modeled after SVG but is not SVG strictly speaking.
For example we may allow length and percentage units to be used there.
It is desirable for it to include normalized SVG path as a subset.
Just to be able to use existing icons and tools.


-- 
Andrew Fedoniouk.

http://sciter.com

Received on Sunday, 20 March 2016 16:50:23 UTC