OK now it is clear. BATIK is the right think to solve your task.
Than all comments from Vincent are correct and the best way to create and remove elements is manipulating the DOM in the update manager. You can retrieve this from JSVGCanvas methode getUpdateManager().getUpdateRunnableQueue().invokeLater(yourDOMUpdateRunnable); here is an code snippet--------------- canvas.getUpdateManager().getUpdateRunnableQueue().invokeLater(new Runnable() { public void run() { Element rectangle = document.createElementNS(svgNS, "rect"); rectangle.setAttributeNS(null, "x", String.valueOf(x)); rectangle.setAttributeNS(null, "y", String.valueOf(y)); rectangle.setAttributeNS(null, "width", String.valueOf(ddx)); rectangle.setAttributeNS(null, "height", String.valueOf(ddy)); rectangle.setAttributeNS(null, "style", "fill:white; stroke:black"); svgRoot.appendChild(rectangle); } //run }); --------------------------------- This is an example to create an rectangle. Jan -----Ursprüngliche Nachricht----- Von: Reinhard Brandstädter [mailto:[EMAIL PROTECTED] Gesendet: Donnerstag, 5. Juni 2003 00:35 An: Batik Users Betreff: Re: AW: AW: Batik and SVG for displaying multiple graphical Objects.. . OK Sorry for causing this confusion. I'll try again but to do so I'll better describe my whole application (real stand alone application not a web application): Imagine I have a stream of Objects (not grapical Objects) let's call them "Events". These Events are to be represented as graphical Objects, let's call these graphical Objects "Representation". So every "Event" get's assigned exactly one "Representation". I want to specify these "Representations" as SVG. Lets say all Events "A" should be displayed as a Representation "blue filled rectangle" ("BFR"), and all Events "B" as "red filled circles" ("RFC") So what happens: I have a screen - call it "Monitor". The Monitor should display all different "Representations". So assume I have a Event stream consisting of the Events: A A B A B We know As should be represented as BFRs and Bs should be displayed as RFCs somewhere on the Monitor for some time and then disapear again. So let's read "A", generate a SVG "BFR" and display this graphic somewhere on the "Monitor", then read the next "A" generate a SVG "BFR" and display it somewhere else on the Monitor, read Event "B" generate SVG "RFC", and display it, meanwhile the Event "A" has "timed out" and we want to remove the Representation for it from the Monitor again...and so on. While Events happen, representations are generated and displayed and removed again...there is a timeline that advances and the content of the Monitor (= different Representations = single SVG) changes when time advances. Sorry for confusing you again, I should have described it like this before. I hope it's a little bit easier to understand now. Thanks, Reinhard Lolling, Jan wrote: > I am a little bit confused... > If you talk about SVGs - do you mean several shapes e.g or do you mean several > graphics ? > SVG-Objects is not an appropriated name for anythink. We talk about svg graphics ore > elements (one svg graphic contains several elements) and one element is one shape or > group. > > JSVGCanvas can only display ONE graphic within several elements. > > Please describe your application architecture. Do you want create a application or > web application ? In the second case you do not need batik and you can deliver and > manipulate your graphic an an servlet e.g. > > Jan > > -----Ursprüngliche Nachricht----- > Von: Reinhard Brandstädter [mailto:[EMAIL PROTECTED] > Gesendet: Mittwoch, 4. Juni 2003 17:22 > An: Batik Users > Betreff: Re: AW: Batik and SVG for displaying multiple graphical > Objects... > > > Lolling, Jan wrote: > >>First of all - SVG is exactly what you need and matching perfect with your request. > > > OK that's good to know! > > So to bring it to one point: > You think it's possible to read several SVGs or create many of them and > then display them independently in a client application. > I think the best description is: I want to write a live-Monitor-like > application (display changing graphical information during execution > time) where all grapical informations shown are single runtime generated > graphics based on SVG input. > > > What would be the best way to display several SVG-Objects (or converted > to Java Swing components) in one single Java Application? > > Maybe my definition is not very clear to understand, sorry for that > > Reinhard > > > >>point 2 >>A good method is e.g. to create the entire svg graphic at runtime from any >>datasource. >>If you want to display the svg graphic in an browser you do not need batik framework. >>I have build a web application what creates svg graphics in a servlet. These >>graphics is shown with the Adobe SVG plugin for IE or Mozilla. >>If you want to build a client application than batik is needed! >> >>There is a mistake or misunderstanding in your point 3. >>JSVGCanvas can only display one document in time not one object. >>A document can containing uncounted among of objects (graphical elements). >>The initialization time is depending from the count and complextity of elements. >> >>Jan >> > > > > --------------------------------------------------------------------- > 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] -- Reinhard Brandstaedter [EMAIL PROTECTED] GPG: 0x033B81DB - Student of Computer Science - J.K. University of Linz - - <ICQ: 73059068> <Mobile: +43 699 12419541> - - http://adelaide.dnsalias.net - --------------------------------------------------------------------- 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]