W3C home > Mailing lists > Public > www-svg@w3.org > August 2000

Re: Why the SVG DOM is so complex to use?

From: Thierry Kormann <Thierry.Kormann@sophia.inria.fr>
Date: Thu, 31 Aug 2000 19:10:46 +0200
Message-Id: <200008311710.e7VHAku11548@quokka.inria.fr>
To: Jon Ferraiolo <jferraio@Adobe.COM>
cc: Thierry Kormann <Thierry.Kormann@sophia.inria.fr>, www-svg@w3.org
> The main reason for the having attributes in the DOM such as 'width' and 
> 'height' are so that you can have object-oriented access to the values, 
> rather than just as strings. Yes, in many cases, string access is 
> sufficient, but in other cases, there is a lot of value in object-oriented 
> access. For example, with an SVGLength, you can determine what unit type 
> was applied without having to write a parser.

Do you mean "without parsing the string" ?

I'm asking this because a conforming viewer should also support setAttribute so 
in any case the viewer must have a parser for CSS units, path, transform...

You can also imagine to use object-oriented access to set a value but use the 
getAttribute method to get the value. In that case, the viewer should create a 
String using the SVGLength.


Thierry.

-- 
Thierry Kormann
email: Thierry.Kormann@sophia.inria.fr  http://www.inria.fr/koala/tkormann/
Koala/Dyade/Bull @ INRIA - Sophia Antipolis
Received on Thursday, 31 August 2000 13:10:55 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Monday, 5 November 2012 23:52:48 GMT