diff --git a/lib/OpenLayers/Renderer.js b/lib/OpenLayers/Renderer.js index ffcabd3c82..7fa249a755 100644 --- a/lib/OpenLayers/Renderer.js +++ b/lib/OpenLayers/Renderer.js @@ -345,7 +345,6 @@ OpenLayers.Renderer = OpenLayers.Class({ * strokeColor: "#000000", * strokeOpacity: 1, * strokeWidth: 1, - * strokeDashstyle: "solid", * pointRadius: 3, * graphicName: "square" * }; @@ -357,7 +356,6 @@ OpenLayers.Renderer.defaultSymbolizer = { strokeWidth: 2, fillOpacity: 1, strokeOpacity: 1, - strokeDashstyle: "solid", pointRadius: 0 }; diff --git a/lib/OpenLayers/Renderer/SVG.js b/lib/OpenLayers/Renderer/SVG.js index f6edf17512..e75e2d6093 100644 --- a/lib/OpenLayers/Renderer/SVG.js +++ b/lib/OpenLayers/Renderer/SVG.js @@ -371,8 +371,8 @@ OpenLayers.Renderer.SVG = OpenLayers.Class(OpenLayers.Renderer.Elements, { // Hard-coded linejoin for now, to make it look the same as in VML. // There is no strokeLinejoin property yet for symbolizers. node.setAttributeNS(null, "stroke-linejoin", "round"); - node.setAttributeNS(null, "stroke-dasharray", this.dashStyle(style, - widthFactor)); + style.strokeDashstyle && node.setAttributeNS(null, + "stroke-dasharray", this.dashStyle(style, widthFactor)); } else { node.setAttributeNS(null, "stroke", "none"); } diff --git a/lib/OpenLayers/Renderer/VML.js b/lib/OpenLayers/Renderer/VML.js index c70697f617..ad72de5fb4 100644 --- a/lib/OpenLayers/Renderer/VML.js +++ b/lib/OpenLayers/Renderer/VML.js @@ -329,7 +329,9 @@ OpenLayers.Renderer.VML = OpenLayers.Class(OpenLayers.Renderer.Elements, { stroke.opacity = style.strokeOpacity; stroke.endcap = style.strokeLinecap == 'butt' ? 'flat' : (style.strokeLinecap || 'round'); - stroke.dashstyle = this.dashStyle(style); + if (style.strokeDashstyle) { + stroke.dashstyle = this.dashStyle(style); + } } if (style.cursor != "inherit" && style.cursor != null) { diff --git a/lib/OpenLayers/Symbolizer/Line.js b/lib/OpenLayers/Symbolizer/Line.js index 4648dc1138..8289988c6f 100644 --- a/lib/OpenLayers/Symbolizer/Line.js +++ b/lib/OpenLayers/Symbolizer/Line.js @@ -40,7 +40,7 @@ OpenLayers.Symbolizer.Line = OpenLayers.Class(OpenLayers.Symbolizer, { * "longdash", "longdashdot", or "solid") will not work in SLD, but * most SLD patterns will render correctly in OpenLayers. */ - strokeDashstyle: "solid", + strokeDashstyle: null, /** * Constructor: OpenLayers.Symbolizer.Line diff --git a/lib/OpenLayers/Symbolizer/Point.js b/lib/OpenLayers/Symbolizer/Point.js index 7781e6efeb..87460c3c5c 100644 --- a/lib/OpenLayers/Symbolizer/Point.js +++ b/lib/OpenLayers/Symbolizer/Point.js @@ -40,7 +40,7 @@ OpenLayers.Symbolizer.Point = OpenLayers.Class(OpenLayers.Symbolizer, { * "longdash", "longdashdot", or "solid") will not work in SLD, but * most SLD patterns will render correctly in OpenLayers. */ - strokeDashstyle: "solid", + strokeDashstyle: null, /** * APIProperty: fillColor diff --git a/lib/OpenLayers/Symbolizer/Polygon.js b/lib/OpenLayers/Symbolizer/Polygon.js index b72a892779..044d4f179f 100644 --- a/lib/OpenLayers/Symbolizer/Polygon.js +++ b/lib/OpenLayers/Symbolizer/Polygon.js @@ -40,7 +40,7 @@ OpenLayers.Symbolizer.Polygon = OpenLayers.Class(OpenLayers.Symbolizer, { * "longdash", "longdashdot", or "solid") will not work in SLD, but * most SLD patterns will render correctly in OpenLayers. */ - strokeDashstyle: "solid", + strokeDashstyle: null, /** * APIProperty: fillColor