xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sylvain Caillet" <s.cail...@free.fr>
Subject XOR Mode to repaint SVG object
Date Thu, 01 Dec 2005 11:23:17 GMT
Hi to all !

I have a Java panel on which i have to allow my users to move a SVG object rendered with the
Batik API. I'm looking for a way to use the XOR technic to efficiently paint/remove my object
during the move.

I currently a code like that to paint the SVG :
---------------- begin code --------------
public void paint(Graphics g) {
// GraphicsNode gn;
 Graphics2D g2d;

 g2d = (Graphics2D)g.create(x,y,width,height);
 g2d.scale(sx, sy);

---------------- end code --------------
Is it possible to use (on g or g2d ?) the setXORMode method ?

Thank you for your help

Best regards

Sylvain Caillet

View raw message