xmlgraphics-batik-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Christian Enklaar <christian.enkl...@mbs-software.de>
Subject RE: Batik 2.0 / <defs><symbol><use> and events
Date Fri, 03 Jan 2003 14:57:06 GMT
>     I think we would be curious to know about the problems with
> dynamic updates.  Obviously, we know about the lack of SMIL support.

One problem is that I change elements in the displayed svg upon messages 
received from a server. My application is kind of monitoring the state of 
a system and usually the user has to note changes while performing other tasks.
But the dynamic update seems only to take place when the mouse is moved over
the batik-application.

Some updates do not work at all. For example size of a rect or the content 
of a text element changes - but not its color (style="fill:rgb(rVal,gVal,bVal)").
The element is not displayed correctly - the style-attribute is changed, but
still the old color is displayed. If I set the (changed) document to the canvas again
everything is correct (tried that as workaround) - but there are many updates and of
course it is no good idea to repaint the complete svg every time.

Some updates only work sometimes - I could not find out when it works and when not.
For example if I change the color of a border of an element upon mouseEnter/mouseLeave
events (the border consists of line-elements with different colors).

With this svg-fragment the color change works dynamically:
<g id="someID" style="visibility:visible" display="inline">         
<rect x="30px" width="84" y="265px" height="18" style="fill:rgb(192,192,192)" />   
<line y2="283px" style="stroke:rgb(240,240,240)" x1="30px" x2="30px" y1="265px" /> 
<line y2="283px" style="stroke:rgb(128,128,128)" x1="114px" x2="114px" y1="265px" />
<line y2="265px" style="stroke:rgb(240,240,240)" x1="30px" x2="114px" y1="265px" />
<line y2="283px" style="stroke:rgb(128,128,128)" x1="30px" x2="114px" y1="283px" />
<text x="36px" y="279px" style="fill:rgb(240,96,16);font-size:14;font-weight:bold;

With this svg-fragment the color change does work dynamically 
(though the color is changed in the svg):
<g ownNS:someAttrib="someVal" display="inline" id="someID" style="visibility:visible">
<rect x="130px" width="29" y="65px" height="18" style="fill:rgb(32,32,192)" /> 
<line y2="83px" style="stroke:rgb(240,240,240)" x1="130px" x2="130px" y1="65px" /> 
<line y2="83px" style="stroke:rgb(128,128,128)" x1="159px" x2="159px" y1="65px" /> 
<line y2="65px" style="stroke:rgb(240,240,240)" x1="130px" x2="159px" y1="65px" /> 
<line y2="83px" style="stroke:rgb(128,128,128)" x1="130px" x2="159px" y1="83px" /> 
<text x="136px" y="79px" style="fill:rgb(0,0,0);font-size:12;font-family:Arial">

Another point is that I use both properties "visibility" and "display".
Dynamic update seems to be supported for the first one only.
I use them both on the same elements in two different situations 
influencing its visibilty in my application.
Are there plans to support dynamic update of "display" as well ?


(I work with a batik cvs version from 09.Dec.2002 right now.)

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

View raw message