Refactored wkt printing for polygons.