W3C home > Mailing lists > Public > www-svg@w3.org > October 2013

Re: Missing values in SVGPathElement API: What to do?

From: Cameron McCormack <cam@mcc.id.au>
Date: Thu, 24 Oct 2013 17:55:42 +0200
Message-ID: <526942FE.9080609@mcc.id.au>
To: Stephen Chenney <schenney@chromium.org>
CC: "www-svg@w3.org" <www-svg@w3.org>
Stephen Chenney wrote:
> I just came across some undefined behavior in the spec that could easily
> be defined. An example is the
> http://www.w3.org/TR/SVG/paths.html#InterfaceSVGPathElement spec. It has
> absolutely nothing to say about cases where the calling script does not
> provide all of the necessary parameters. I could find no blanket
> statement in the spec about what to do in such cases. The canvas spec is
> similarly unhelpful.
>
> e.g. what to do with
> pathSegment = pathElement.createSVGPathSegCurvetoCubicAbs(1.0)

SVG 2 uses Web IDL, which requires a TypeError be thrown when too few 
required arguments are passed.
Received on Thursday, 24 October 2013 15:56:22 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:54:46 UTC