Closed jrjdavidson closed 4 years ago
Currently only option is to use HTML text. There is example (you have to hover over line):
https://jsfiddle.net/yLduqhL8/
another option is to use debug text function (no as fancy as HTML but sometime is good enough):
renderer.drawDebugText(options)
supported options are: text : "string" coords: [screenX, screenY] color: [r,g,b,a] size : numer depth : number useState : bool
there is example: https://www.melowntech.com/mercury/?pos=obj,-100.782187,48.617979,fix,-1382.64,-156.38,-90.00,0.00,3020166.57,55.00
there is example source code: https://cdn.melown.com/static/web/homepage-web-static/mercury/main.js?2.37
renderer.drawDebugText() is exactly what I was after, thanks.
Is there a simple way to render labels using dynamic rendering (onCustomRender)? The gpx viewer adds a control and positions it on custom render, but this method seems quite convoluted. Especially as I'm hoping to have the users add points dynamically to the map.