[whatwg] Canvas.cloneNode()

On Fri, 30 Oct 2009 12:03:46 -0400, OmegaJunior  
<omegajunior at omegajunior.net> wrote:

> Greetings,
>
> Since Last Call was announced and I just ran into this problem, hereby
> this question:
>
> If an image is drawn on a Canvas element, and subsequently the
> javascript function cloneNode(true) is executed for that element,
> should the clone include a copy of the source canvas image, or should
> it show an empty space?

I think it'd be cool if the clone showed the image. But, I'm pretty sure  
cloneNode(true) is just supposed to create a new canvas element with the  
same attributes and childNodes as the original. It's not supposed to copy  
everything that's going on with the element being copied.

There are some exceptions with state for certain elements. Perhaps that  
can happen with canvas too.

-- 
Michael

Received on Saturday, 14 November 2009 17:20:32 UTC