Re: [jQuery] interface: how to get canvas elements to stay visible while dragging

2006-10-25 Thread Andy Triboletti
Nah, I'm not talking about ghosting.  The problem I have is that the  
canvas element doesn't show up while performing the drag operation  
(with ghosting: true, or not).  Here's an example

http://tunebounce.com/jquery-question/interface-canvas-test.html

On Oct 25, 2006, at 12:20 AM, Dan Atkinson wrote:

>
> Are you referring to ghosting like in the demo?
>
> http://interface.eyecon.ro/demos/drag.html
>
>
> Andy Triboletti wrote:
>>
>> I would like to drag a canvas element around, and have the screen  
>> updated
>> while dragging it like it does with a div.  The code below lets me  
>> drag
>> the
>> canvas, but the screen does not update while the drag is  
>> happening, it
>> only
>> displays the rectangle after the drop.  The canvas disapears while  
>> the
>> drag
>> is happening.  Does anyone have any ideas about how to do this, maybe
>> using
>> onDrag?
>>
>> Thanks!
>>
>> canvas = document.createElement("canvas");
>> canvas.setAttribute('id', 'canvas');
>> ctx = canvas.getContext("2d");
>> canvas.height=300;
>> canvas.width=300;
>> ctx.fillRect (10, 10, 55, 50);
>> document.body.appendChild(canvas);
>> $('#canvas').Draggable();
>>
>> ___
>> jQuery mailing list
>> discuss@jquery.com
>> http://jquery.com/discuss/
>>
>>
>
> -- 
> View this message in context: http://www.nabble.com/interface%3A- 
> how-to-get-canvas-elements-to-stay-visible-while-dragging-- 
> tf2506561.html#a6989499
> Sent from the JQuery mailing list archive at Nabble.com.
>
>
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


Re: [jQuery] interface: how to get canvas elements to stay visible while dragging

2006-10-25 Thread Dan Atkinson

Are you referring to ghosting like in the demo?

http://interface.eyecon.ro/demos/drag.html


Andy Triboletti wrote:
> 
> I would like to drag a canvas element around, and have the screen updated
> while dragging it like it does with a div.  The code below lets me drag
> the
> canvas, but the screen does not update while the drag is happening, it
> only
> displays the rectangle after the drop.  The canvas disapears while the
> drag
> is happening.  Does anyone have any ideas about how to do this, maybe
> using
> onDrag?
> 
> Thanks!
> 
> canvas = document.createElement("canvas");
> canvas.setAttribute('id', 'canvas');
> ctx = canvas.getContext("2d");
> canvas.height=300;
> canvas.width=300;
> ctx.fillRect (10, 10, 55, 50);
> document.body.appendChild(canvas);
> $('#canvas').Draggable();
> 
> ___
> jQuery mailing list
> discuss@jquery.com
> http://jquery.com/discuss/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/interface%3A-how-to-get-canvas-elements-to-stay-visible-while-dragging--tf2506561.html#a6989499
Sent from the JQuery mailing list archive at Nabble.com.


___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/


[jQuery] interface: how to get canvas elements to stay visible while dragging?

2006-10-25 Thread Andy Triboletti
I would like to drag a canvas element around, and have the screen updated while dragging it like it does with a div.  The code below lets me drag the canvas, but the screen does not update while the drag is happening, it only displays the rectangle after the drop.  The canvas disapears while the drag is happening.  Does anyone have any ideas about how to do this, maybe using onDrag?  
Thanks!
canvas = document.createElement("canvas");canvas.setAttribute('id', 'canvas');ctx = canvas.getContext("2d");canvas.height=300;canvas.width=300;ctx.fillRect (10, 10, 55, 50);
document.body.appendChild(canvas);$('#canvas').Draggable();  

___
jQuery mailing list
discuss@jquery.com
http://jquery.com/discuss/