texts.setAttribute(SVGAttributes.SVG_FONT_SIZE, String.valueOf(shape.getLabelsSize()));
texts.setAttribute(SVGAttributes.SVG_STROKE, CSSColors.INSTANCE.getColorName(gridLabelsColor, true));
texts.setAttribute(prefix+LNamespace.XML_TYPE, LNamespace.XML_TYPE_TEXT);
for(i=tlx + (isYLabelWest ? width+gridLabelsSize/4. : -width-labelWidth-gridLabelsSize/4.), j=minX; j<=maxX; i+=absStep, j++) {
text = new SVGTextElement(document);
text.setAttribute(SVGAttributes.SVG_X, String.valueOf((int)i));
text.setAttribute(SVGAttributes.SVG_Y, String.valueOf((int)(yorigin+tmp)));
text.setTextContent(String.valueOf((int)j));
texts.appendChild(text);
}
if(isYLabelWest)
for(i=tly + (isXLabelSouth ? -width-gridLabelsSize/4. : width+labelHeight), j=maxY ; j>=minY; i+=absStep, j--) {
label = String.valueOf((int)j);
text = new SVGTextElement(document);
text.setAttribute(SVGAttributes.SVG_X, String.valueOf((int)(xorigin-fontMetrics.stringWidth(label)-gridLabelsSize/4.-width)));
text.setAttribute(SVGAttributes.SVG_Y, String.valueOf((int)i));
text.setTextContent(label);
texts.appendChild(text);
}
else
for(i=tly + (isXLabelSouth ? -width-gridLabelsSize/4. : width+labelHeight), j=maxY; j>=minY; i+=absStep, j--) {
label = String.valueOf((int)j);
text = new SVGTextElement(document);
text.setAttribute(SVGAttributes.SVG_X, String.valueOf((int)(xorigin+gridLabelsSize/4.+width)));
text.setAttribute(SVGAttributes.SVG_Y, String.valueOf((int)i));
text.setTextContent(label);
texts.appendChild(text);
}