SetMarkerStyle
(TLayer.SetMarkerStyle Method)
Set the style of all the markers on the layer which this method is applied to.
public SetMarkerStyle(strStyle):Void
Parameters
strStyle : String - A string that specifies the style of the markers. It can only have any combination of the following attributes: (seperate each attribute with ; except for the last one)
a. MARKER_SIZE : Number - Set the sizes of the markers.
b. MARKER_COLOR : Hex Color Code - Set all the markers to this color.
c. MARKER_ALPHA : Number - Set the alpha value for all the markers on this layer.
d. BORDER_WIDTH : Number - Set the border of all the markers on this to to this width.
e. BORDER_COLOR : Hex Color Code - Set all the marker borders to this color.
f. BORDER_ALPHA : Number - Set all marker borders to this alpha.
g. FONT : String - Set the font of all the markers on this layer to this font.
h. FONT_COLOR : Hex Color Code - Set the text of all the markers to this color.
i. FONT_ALPHA : Number - Set the alpha of the text of all the markers to this value.
Returns
Void
Example
The following example shows how to set all markers'font color to the specified value on the layer.
<div id="mapContainer" style="width: 640px; height: 400px;"></div>
<script type="text/javascript">
var map0 = new TMap(mapContainer, 25.7590256665386, -80.3738769902151, 15, mapLoaded, 1, true, "", "hybrid");
function mapLoaded() {
var layer0=map0.AddLayer();
var marker0=layer0.AddMarker(25.759025666538, -80.3708769902151, "Text Marker0");
var marker1=layer0.AddMarker(25.759025666538, -78.3708769902151, "Text Marker1");
layer0.SetMarkerStyle("MARKER_SIZE=20;MARKER_COLOR=0xFFFFFF;FONT=Times New Roman;FONT_COLOR=0xCCCCCC");
}
</script>
See also
AddMarker()