I want to change my text backcolor.
new ol.style.Style({
text: new ol.style.Text({
text: marker_name,
fill: new ol.style.Fill({
color: '#fff'
})
})
})
"fill" property change text color.
I search from OpenLayers v4.0.1 ol.style.text but I did not find propery for this.
You think draw a shape under the text like this
new ol.style.Style({
image: new ol.style.RegularShape({
fill: fill,
//stroke: stroke,
// offsetY: -25,
points: 4,
radius1: 30,
radius2:10,
angle: Math.PI / 4
}),
text: new ol.style.Text({
text: marker_name,
fill: new ol.style.Fill({
color: '#fff'
})
})
But OpenLayers v4 can't draw rectange in style. For this issue you can look that.