- From: Don XML <don_xml@hotmail.com>
- Date: Wed, 11 Dec 2002 14:34:53 -0500
- To: www-svg@w3.org
Jim, I'm having a hard time understanding your following statement. Can you clarify it: <Jim> I have a problem with this view, I would say, that with SVG within another document, the SvgWindow doesn't exist, what would innerHeight and innerWidth be in this situation (we don't even know the viewport would be rectangular for example, let alone its size)? The defaultStyleSheet attribute is also presumably intended to overcome problems the problems with not knowing what that stylesheet is, but that doesn't help in a mixed namespace document since you don't know what other CSS rules are coming down from the other namespace. I think having svgWindow outside of viewers of SVG Documents is too problematic. </Jim> If the SvgWindow doesn't exist, and the SvgDocument doesn't exist (since the SVG element isn't the root element the 1.1 spec says a SvgDocument can't exist) how do your create a SvgElement? What is the root object that can create SVG objects? That's what lead me to a DocFragment approach. I also agree that the SvgWindow doesn't make total sense outside of viewer applications, but without it some SVG DOM methods can not return values in some situations. Take the following example: <?xml version="1.0" standalone="yes"?> <parent xmlns="http://example.org" xmlns:svg="http://www.w3.org/2000/svg"> <!-- parent contents here --> <svg:svg width="100%" height="100%" version="1.1"> <svg:ellipse cx="2cm" cy="4cm" rx="2cm" ry="1cm" /> </svg:svg> <!-- ... --> </parent> What is the width and height of the SVG? It's 100% of the parent element, but what's the height and width of the parent element? In section 7.2 it is described as: In the following example, an SVG graphic is embedded inline within a parent XML document which is formatted using CSS layout rules. Since CSS positioning properties are not provided on the outermost 'svg' element, the width="100px" and height="200px" attributes determine the size of the initial viewport. But in my example I changed the height and width of the parent element, so you need some way of letting informing the SVG fragment the size of the parent element, otherwise you can not create an initial viewport. Don XML Always listen to experts. They'll tell you what can't be done, and why. Then do it. _________________________________________________________________ The new MSN 8: smart spam protection and 2 months FREE* http://join.msn.com/?page=features/junkmail
Received on Wednesday, 11 December 2002 14:41:00 UTC