1.7. SVG <ellipse>

发布时间 : 2025-10-25 13:33:32 UTC      

Page Views: 9 views

1.7.1. SVG Ellipse-

Example 1

Element is used to create an ellipse:

An ellipse is very similar to a circle. The difference is that the ellipse has different x and y radii, while the x and y radii of the circle are the same:

Here is the SVG code:

Example

<svgxmlns="http://www.w3.org/2000/svg"version="1.1"><ellipsecx="300"cy="80"rx="100"ry="50"style="fill:yellow;stroke:purple;stroke-width:2"/>svg>    

For Opera users: view the SVG file (right-click the SVG drawing preview source).

Code parsing:

  • The x coordinate of the center of the ellipse defined by the CX property

  • The y coordinate of the center of the ellipse defined by the CY property

  • Horizontal radius defined by the RX attribute

  • The vertical radius defined by the RY attribute

Example 2

The following example creates three superimposed ellipses:

Here is the SVG code:

Example

<svgxmlns="http://www.w3.org/2000/svg"version="1.1"><ellipsecx="240"cy="100"rx="220"ry="30"style="fill:purple"/><ellipsecx="220"cy="70"rx="190"ry="20"style="fill:lime"/><ellipsecx="210"cy="45"rx="170"ry="15"style="fill:yellow"/>svg>    

For Opera users: view the SVG file (right-click the SVG drawing preview source).

Example 3

The following example combines two ellipses (one yellow and one white):

Here is the SVG code:

Example

<svgxmlns="http://www.w3.org/2000/svg"version="1.1"><ellipsecx="240"cy="50"rx="220"ry="30"style="fill:yellow"/><ellipsecx="220"cy="50"rx="190"ry="20"style="fill:white"/>svg>    

For Opera users: view the SVG file (right-click the SVG drawing preview source).

《地理信息系统原理、技术与方法》  97

最近几年来,地理信息系统无论是在理论上还是应用上都处在一个飞速发展的阶段。 GIS被应用于多个领域的建模和决策支持,如城市管理、区划、环境整治等等,地理信息成为信息时代重要的组成部分之一; “数字地球”概念的提出,更进一步推动了作为其技术支撑的GIS的发展。 与此同时,一些学者致力于相关的理论研究,如空间感知、空间数据误差、空间关系的形式化等等。 这恰好说明了地理信息系统作为应用技术和学科的两个方面,并且这两个方面构成了相互促进的发展过程。