1.7. SVG <ellipse>

发布时间 :2023-12-07 00:55:31 UTC      

1.7.1. SVG Ellipse- <ellipse>

Example 1

<ellipse> 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).

Principles, Technologies, and Methods of Geographic Information Systems  102

In recent years, Geographic Information Systems (GIS) have undergone rapid development in both theoretical and practical dimensions. GIS has been widely applied for modeling and decision-making support across various fields such as urban management, regional planning, and environmental remediation, establishing geographic information as a vital component of the information era. The introduction of the “Digital Earth” concept has further accelerated the advancement of GIS, which serves as its technical foundation. Concurrently, scholars have been dedicated to theoretical research in areas like spatial cognition, spatial data uncertainty, and the formalization of spatial relationships. This reflects the dual nature of GIS as both an applied technology and an academic discipline, with the two aspects forming a mutually reinforcing cycle of progress.