1.

How to draw a ellipse in SVG?

Answer»

'ellipse' tag of SVG is used to draw a ellipse. Following are the commonly used attributes −

  • cx − x-axis co-ordinate of the center of the ellipse. Default is 0.

  • cy − y-axis co-ordinate of the center of the ellipse. Default is 0.

  • rx − x-axis radius of the ellipse.

  • ry − y-axis radius of the ellipse.

Example −

<ellipse cx = "100" cy = "100" rx = "90" ry = "50" stroke = "black" stroke-width = "3" fill = "rgb(121,0,121)">


Discussion

No Comment Found