public void writeObject(Object o, GraphicsDocument document, boolean asChild) throws RenderException {
document.writeElement("vml:shape", asChild);
document.writeAttribute("fill-rule", "evenodd");
document.writeAttributeStart("path");
Polygon poly = (Polygon) o;
LineString shell = poly.getExteriorRing();
int nHoles = poly.getNumInteriorRing();
document.writeClosedPathContent(shell.getCoordinates());
for (int j = 0; j < nHoles; j++) {
document.writeClosedPathContent(poly.getInteriorRingN(j).getCoordinates());
}
document.writeAttributeEnd();
}