if(i==0){
pointPath.append("M");
}else{
pointPath.append("L");
}
SvgPoint point = pointList.get(i);
pointPath.append(point.getX());
pointPath.append(" ");
pointPath.append(point.getY());
}
if(size!=0 && size%2==0){
SvgPoint leftPoint = pointList.get(size/2-1);
SvgPoint rightPoint = pointList.get(size/2);
textx = String.valueOf((leftPoint.getX()+rightPoint.getX())/2);
texty = String.valueOf((leftPoint.getY()+rightPoint.getY())/2);
}else{
int position = size/2;
SvgPoint middlePoint = pointList.get(position);
textx = String.valueOf(middlePoint.getX());
texty = String.valueOf(middlePoint.getY());
}
str = FlowSvgUtil.replaceAll(str, path, pointPath.toString());
str = FlowSvgUtil.replaceAll(str, text_x, textx);
str = FlowSvgUtil.replaceAll(str, text_y, texty);