Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork7.9k
Open
Description
When saving a scene as SVG, circles are translated to<path>
elements. For example
importmatplotlib.pyplotaspltcirc=plt.Circle((0.0,0.0),1.0,alpha=0.5)plt.gca().add_patch(circ)plt.autoscale()plt.gca().set_aspect("equal")plt.gca().set_axis_off()# plt.show()plt.savefig("out.svg")
<gid="patch_2"> <pathclip-path="url(#p50a8cc0149)"d="M 236.16 295.488.C 268.238967 295.488 299.008381 282.742891 321.691636 260.059636.C 344.374891 237.376381 357.12 206.606967 357.12 174.528.C 357.12 142.449033 344.374891 111.679619 321.691636 88.996364.C 299.008381 66.313109 268.238967 53.568 236.16 53.568.C 204.081033 53.568 173.311619 66.313109 150.628364 88.996364.C 127.945109 111.679619 115.2 142.449033 115.2 174.528.C 115.2 206.606967 127.945109 237.376381 150.628364 260.059636.C 173.311619 282.742891 204.081033 295.488 236.16 295.488.z"style="fill:#1f77b4;opacity:0.5;"/> </g>
A better suited approach would be SVG's own<circle>
element:
<circlecx="236"cy="174.5"r="121"fill="red" />