[whatwg] proposed canvas 2d API additions

Ian Hickson ian at hixie.ch
Wed Apr 26 13:13:02 PDT 2006

On Mon, 24 Apr 2006, Vladimir Vukicevic wrote:
> >
> > Assuming nobody has any problem with:
> >
> >    boolean isPointInPath(in float x, in float y);
> >
> > ...then I'll add that to the spec when you reply to this mail.
> Sure, isPointInPath sounds fine.


> We can always add isPointInStrokedPath if we ever want to bother with 
> that (which is where the "...Fill" bit came from in my API, because the 
> region covered by a stroked path and that covered by a filled path are 
> different, even though testing for a hit against a filled region would 
> by far be the common case).

We can also call the other one isPointOnPath(), if we want to keep the 
method names reasonably short. I'm not sure we'll ever need to add it, 
though. Getting people to click on a line is generally silly.

Ian Hickson               U+1047E                )\._.,--....,'``.    fL
http://ln.hixie.ch/       U+263A                /,   _.. \   _\  ;`._ ,.
Things that are impossible just take longer.   `._.-(,_..'--(,_..'`-.;.'

More information about the whatwg mailing list