Fork me on GitHub

OL3-ext: style textPath

The ol.vector.setTextPathStyle() is a function to draw text along a linear feature (ol.geom.lineString) on postcompose.
The function is called as the ol.vector.setStyle() function but rendered in a postcompose frame.
An ol.style.TextPath is defined but ol.style.Text can be used instead.
You can specify a minResolution to prevent drawing beneath this resolution. The example uses an ol.geom.LineString.cspline to smooth support and avoid letters collision.

Options:

textAlign:
textBaseline:
textOverflow:
minWidth: px


minZoom: (~ maxResolution)