PictureMarkerSymbol with border?

989
1
01-17-2011 05:10 AM
AxelSchaefer
New Contributor II
Hi.

I want to create a PictureMarkerSymbol with a white border (2px) around it. Can anybody tell me how to do it? I don't know, why I'm stuck at this point. :confused:

This code doesn't do it.
var symbol = new esri.symbol.PictureMarkerSymbol(item.photo_file_url, 32, 32);
            symbol.setSize(35);
            symbol.setColor(new dojo.Color([255, 255, 255]));


The goal is: If I add the Picture Marker Symbols to the map, they overlap. With a small border it's easier to differentiate them.

Thanks in advance...
Axel
0 Kudos
1 Reply
timgogl
New Contributor II
so, your pic is like 28x28? and your setting the h,w to 32x32 to get a background white border to show through?

doesn't the constructor just stretch the pic to fit the actual parameters set (ie 32x32)? thus hiding your white border?

if this is the case (and i am not sure it is), could you use 2 symbols? one larger (and under) the other? with the pic on top of the other symbol?
0 Kudos