root.setAttribute(LNamespace.LATEXDRAW_NAMESPACE+':'+LNamespace.XML_TYPE, LNamespace.XML_TYPE_CIRCLE);
root.setAttribute(SVGAttributes.SVG_ID, getSVGID());
final double gap = getPositionGap();
if(shape.hasShadow()) {
shad = new SVGCircleElement((brx+tlx)/2., (bry+tly)/2., (brx-tlx+gap)/2., doc);
setSVGShadowAttributes(shad, true);
root.appendChild(shad);
}
if(shape.hasShadow() && !shape.getLineStyle().getLatexToken().equals(PSTricksConstants.LINE_NONE_STYLE)){
// The background of the borders must be filled is there is a shadow.
elt = new SVGCircleElement((brx+tlx)/2., (bry+tly)/2., (brx-tlx+gap)/2., doc);
setSVGBorderBackground(elt, root);
}
elt = new SVGCircleElement((brx+tlx)/2., (bry+tly)/2., (brx-tlx+gap)/2., doc);// FIXME Should use prototype design pattern to reduce re-creation.
root.appendChild(elt);
if(shape.hasDbleBord()) {
dblBord = new SVGCircleElement((brx+tlx)/2., (bry+tly)/2., (brx-tlx+gap)/2., doc);
setSVGDoubleBordersAttributes(dblBord);
root.appendChild(dblBord);
}
setSVGAttributes(doc, elt, true);