ajstarks / svgo

Go Language Library for SVG generation
Other
2.14k stars 169 forks source link

Add method for rotation around the center #65

Open rasha108bik opened 2 years ago

rasha108bik commented 2 years ago

func (svg *SVG) RotateCenter(r float64, x, y int) { svg.Gtransform(rotateCenter(r, x, y)) }

func rotateCenter(r float64, x, y int) string { return fmt.Sprintf(rotate(%g %d %d), r, x, y) }