root.setAttribute(LNamespace.LATEXDRAW_NAMESPACE+':'+LNamespace.XML_TYPE, LNamespace.XML_TYPE_RHOMBUS);
root.setAttribute(SVGAttributes.SVG_ID, getSVGID());
if(shape.hasShadow()) {
elt = new SVGPolygonElement(doc);
elt.setAttribute(SVGAttributes.SVG_POINTS, points);
setSVGShadowAttributes(elt, true);
root.appendChild(elt);
}
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 SVGPolygonElement(doc);
elt.setAttribute(SVGAttributes.SVG_POINTS, points);
setSVGBorderBackground(elt, root);
}
elt = new SVGPolygonElement(doc);
elt.setAttribute(SVGAttributes.SVG_POINTS, points);
root.appendChild(elt);
root.setAttribute(LNamespace.LATEXDRAW_NAMESPACE+':'+LNamespace.XML_POINTS, String.valueOf(tl.getX()) + ' ' +
tl.getY() + ' ' + br.getX() + ' ' + tl.getY() + ' ' + tl.getX() + ' ' + br.getY() + ' ' + br.getX() + ' ' + br.getY());
if(shape.hasDbleBord()) {
final SVGElement dblBord = new SVGPolygonElement(doc);
dblBord.setAttribute(SVGAttributes.SVG_POINTS, points);
setSVGDoubleBordersAttributes(dblBord);
root.appendChild(dblBord);
}
setSVGAttributes(doc, elt, true);