1.

How to draw a circle in SVG?

Answer»

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

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

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

  • r − radius of the circle.

Example −

<circle cx = "100" cy = "100" r = "50" stroke = "black" stroke-width = "3" fill = "rgb(121,0,121)" >


Discussion

No Comment Found