You are viewing a plain text version of this content. The canonical link for it is here.
Posted to batik-users@xmlgraphics.apache.org by javaNoob <no...@yahoo.com> on 2008/07/03 01:25:11 UTC

RE: Select an element and draw it on the canvas without updating the svg

overlay is the right way to go! thanks.. another question.. what do you mean
by i'd have to get from svg to graphics? get the element node? or are there
other approaches on getting the shape?



Bishop, Michael W. CONTR J9C880 wrote:
> 
> If you're looking at drawing on the canvas without updating the SVG,
> perhaps you're looking for something like an Overlay?  You'd have to get
> from SVG to Graphics, but an Overlay draws on top of a canvas without
> updating the canvas itself.
> 
> Michael Bishop
> 
> 
> 
> From: javaNoob
> Sent: Mon 6/30/2008 2:41 AM
> To: batik-users@xmlgraphics.apache.org
> Subject: Select an element and draw it on the canvas without updating the
> svg
> 
> 
> how can i select an element, copy the image of that element and draw it on
> the canvas without updating the canvas? without updating meaning that i do
> not have to add the duplicate element to the svg in order to view it..
> what
> classes do i have to look at?
> -- 
> View this message in context:
> http://www.nabble.com/Select-an-element-and-draw-it-on-the-canvas-without-updating-the-svg-tp18189565p18189565.html
> Sent from the Batik - Users mailing list archive at Nabble.com.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
> For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org
> 
> 

-- 
View this message in context: http://www.nabble.com/Select-an-element-and-draw-it-on-the-canvas-without-updating-the-svg-tp18189565p18248994.html
Sent from the Batik - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org


RE: Select an element and draw it on the canvas without updating the svg

Posted by th...@kodak.com.
Hi JavaNoob,

javaNoob <no...@yahoo.com> wrote on 07/04/2008 04:27:13 AM:

> i can now drag a shape in the overlay.. but when i drag, it does not 
erase
> the previous image.. the svg is now filled with the shape's trail and 
the
> svg is now covered and cannot be seen.. how do i drag and remove the 
trail?

   It sounds like you aren't triggering a repaint of the canvas.
You probably need to look at calling immediateRepaint() on the canvas
(or if you know you are in the swing thread the standard 'repaint' method.
 

RE: Select an element and draw it on the canvas without updating the svg

Posted by javaNoob <no...@yahoo.com>.
i can now drag a shape in the overlay.. but when i drag, it does not erase
the previous image.. the svg is now filled with the shape's trail and the
svg is now covered and cannot be seen.. how do i drag and remove the trail?
-- 
View this message in context: http://www.nabble.com/Select-an-element-and-draw-it-on-the-canvas-without-updating-the-svg-tp18189565p18275173.html
Sent from the Batik - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org


RE: Select an element and draw it on the canvas without updating the svg

Posted by javaNoob <no...@yahoo.com>.
No, wait.. i always return true in the startInteraction() and its working
now.. is this ok?


javaNoob wrote:
> 
> help!!! how can i add events on the overlays and visually update them w/o
> repainting/rendering the svg? overlays are only updated when the svg is
> rerendered/updated.. i want to update the overlay independently with the
> canvas.. how can i do this?
> 

-- 
View this message in context: http://www.nabble.com/Select-an-element-and-draw-it-on-the-canvas-without-updating-the-svg-tp18189565p18273954.html
Sent from the Batik - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org


RE: Select an element and draw it on the canvas without updating the svg

Posted by javaNoob <no...@yahoo.com>.
help!!! how can i add events on the overlays and visually update them w/o
repainting/rendering the svg? overlays are only updated when the svg is
rerendered/updated.. i want to update the overlay independently with the
canvas.. how can i do this?
-- 
View this message in context: http://www.nabble.com/Select-an-element-and-draw-it-on-the-canvas-without-updating-the-svg-tp18189565p18273753.html
Sent from the Batik - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org


RE: Select an element and draw it on the canvas without updating the svg

Posted by javaNoob <no...@yahoo.com>.
follow up question.. how can i add events on the overlays and visually update
them w/o updating the svg?



javaNoob wrote:
> 
> overlay is the right way to go! thanks.. another question.. what do you
> mean by i'd have to get from svg to graphics? get the element node? or are
> there other approaches on getting the shape
> 

-- 
View this message in context: http://www.nabble.com/Select-an-element-and-draw-it-on-the-canvas-without-updating-the-svg-tp18189565p18272217.html
Sent from the Batik - Users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: batik-users-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: batik-users-help@xmlgraphics.apache.org