问题
In jVectorMap, I tried to find a solution to show the marker labels permanently, but I couldn't make it. I also didn't find anything about it in the documentation.
I just want the marker labels initially shown. Any suggestions?
回答1:
There isn't a quick or simple one.
The way jVectorMap displays labels is by using a div and a label property/object for the map object, which changes its position and text.
If you want static permanent labels you'll have to construct and position and show them from scratch or you could clone the label object and set show()
to be the default. Also, you'd have to code out the conflict of overlapping labels on mouse over map.
来源:https://stackoverflow.com/questions/18382213/how-to-show-marker-labels-permanently