- From: Jon Ferraiolo <jferraio@Adobe.COM>
- Date: Mon, 22 Feb 1999 16:04:52 -0800
- To: andreww@netscape.com (Andrew Wooldridge)
- Cc: svg <www-svg@w3.org>
At 03:01 PM 2/22/99 -0800, Andrew Wooldridge wrote: >In Flash you can tell the image "not" to scale with the document - is >(will be) this possible with SVG? >I imagine it would work just like images where if the width and height >are relative (%) then it scales and if absolute then it doesnt? I agree that this is a requirement. When an SVG drawing/fragment is part of a parent's XML/CSS page, you define the box for the SVG drawing/fragment using CSS positioning. Thus, the box for the SVG drawing can be defined just like images (i.e., percentages or absolute width/height). In the following example, the <g> element is an SVG fragment which is given a width of 10% of the width of its containing block (i.e., the frame) and a height of 300 pixels: <?xml version="1.0"?> <MyXMLPage xmlns="..."> <!-- Now include an SVG fragment --> <g xmlns="...svg..." style="width: 10% height: 300px"> <!-- Contents of the SVG fragment ... --> </g> </MyXMLPage> In the WG, we are also talking about adding a capability such that SVG drawings can be self-sizing (i.e., the contents of the drawing determine how how to compute content-width and content-height): images can be self-sizing, so it seems very graphics should, also. Once you have defined your box for the SVG drawing/fragment, then you get to control whether the SVG drawing/fragment should scale to fit the box, or whether it should stay a particular size no matter what. The main way that you get an SVG drawing/fragment to scale to fit is the 'transform: fit(...)' property (see section 8.7 in the current draft spec). Jon Ferraiolo Adobe Systems Incorporated Member of SVG working group
Received on Monday, 22 February 1999 19:02:24 UTC