[whatwg] [Canvas][WebIDL] Canvas .addText takes NoInterfaceObject argument
dschulze at adobe.com
Wed Jul 3 08:50:29 PDT 2013
On Jul 3, 2013, at 7:17 AM, Ian Hickson <ian at hixie.ch> wrote:
> On Tue, 2 Jul 2013, Dirk Schulze wrote:
>> The methods addText() and addPathByStrokingText()  take the
>> NoInterfaceObject CanvasDrawingStyle  as argument. I wonder if that
>> is even possible for WebIDL since there is no way to create it and no
>> binding to ECMAScript is exposed. Shouldn't it rather be a DrawingStyle
>> object, which indeed is an interface? I didn't scan if that is the
>> case in other places as well. The definition of NoInterfaceObject is
>> here .
> On Wed, 3 Jul 2013, Boris Zbarsky wrote:
>> [NoInterfaceObject] just means that window.CanvasDrawingStyle is
>> undefined, basically. It doesn't affect anything else.
>> addText, as an example, takes any object that implements the
>> CanvasDrawingStyle interface. That would include any DrawingStyle
>> object and any CanvasRenderingContext2D object, at first glance.
> Boris is correct.
Thanks for the clarification.
> Ian Hickson U+1047E )\._.,--....,'``. fL
> http://ln.hixie.ch/ U+263A /, _.. \ _\ ;`._ ,.
> Things that are impossible just take longer. `._.-(,_..'--(,_..'`-.;.'
More information about the whatwg