如何在HTML中以不同的大小呈现SVG?
鉴于此,svg:如何在HTML中以不同的大小呈现SVG?,svg,Svg,鉴于此,svg: <svg width="640" height="480" xmlns="http://www.w3.org/2000/svg"> <!-- Created with SVG-edit - http://svg-edit.googlecode.com/ --> <g> <title>Layer 1</title> <ellipse stroke="#000000" ry="210.999999" rx
<svg width="640" height="480" xmlns="http://www.w3.org/2000/svg">
<!-- Created with SVG-edit - http://svg-edit.googlecode.com/ -->
<g>
<title>Layer 1</title>
<ellipse stroke="#000000" ry="210.999999" rx="259.000004" id="svg_1" cy="237.727263" cx="324.999989" stroke-width="5" fill="#FF0000"/>
</g>
</svg>
第一层
如何将其扩展到用户320x240,而不必重新计算其中的数字?这可能吗?使用该属性控制您在页面中看到的内容。或者将内容包装在
元素中,并在其上设置0.5的缩放变换。使用该属性控制您在页面中看到的内容。或者将内容包装在
元素中,并在其上设置0.5的缩放变换。添加viewBox=“0 0 0 640 480”
并将宽度=“320”高度=“240”
设置为
元素以缩放SVG。您可以在宽度
和高度
上发疯,并使用该属性控制纵横比。添加viewBox=“0 640 480”
并将width=“320”height=“240”
设置为
元素以缩放SVG。您可以在宽度
和高度
上发疯,并使用该属性控制纵横比