HI,

Thanx for the quick reply. I already use the 1.5b (CVS, updated today). 
If I look into the JGVTComponent into renderGVTTree I see something like 
this:

Shape s = inv.createTransformedShape
             (new Rectangle(0, 0, d.width, d.height));

// Rendering thread setup.
gvtTreeRenderer = new GVTTreeRenderer(
        renderer,
        renderingTransform,
         doubleBufferedRendering,
         s, d.width, d.height);

Looks like everything is repainted instead of the changed part (which my 
eyes confirm in a test). Or do I have to call some other methode than 
setDocument, to perform only a partial repaint (hopefully leaving the 
already painted things on screen and only repainting the changed part)?

Kind regards,

Michael.

P.S. Btw, I work on a PII 350 with Linux SuSe 7.2 / KDE 2.2.2, not too 
fast I guess ;-)

Thomas E Deweese wrote:
>>>>>>"MV" == M van Veen <[EMAIL PROTECTED]> writes:
>>>>>
> 
> MV> Does somebody know if it is possible to repaint only the part
> MV> which has changed (int the DOMtree) on the SVGCanvas?
> 
>     You don't say what version of Batik you are using but from the
> question I assume 1.1.1.  If you switch to CVS this should happen
> 'automagically' for many things.  There are still a number of very
> tricky SVG constructs for which this does not work (Patterns for
> example).  The 1.5beta1 handles some simple changes but the current
> CVS handles a lot more.
> 
> MV> After I have changed something in the DOM tree, I call
> MV> setDocument( getDocument() ) and it repaints, but it renders the
> MV> WHOLE image which is rather slow. When I looked at the code I saw
> MV> that it is possible to specify an area of interest to render. But
> MV> to do this I have to rewrite a lot of methodes ( for example the
> MV> on in JGVTComponent.renderGVTTree() (which will of course change
> MV> in the near future) : not a good plan.
> 
> MV> So is there away around this, or is this going to be implemented
> MV> in the near future? (Maybe it's an idea when a change is made in
> MV> de DOMtree to get the GraphicsNode of the element and ask its
> MV> transformedbounds, and only repaint this part in the canvas, after
> MV> building the gvttree (or a part) again?)
> 
>     We do these sorts of optimizations in the 1.5 branch of things.
> 
> MV> Kind regards, and keep up the good work!
> 
>     Thanks, I hope you find the CVS Batik more useful for your work.
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to