[OpenLayers-Users] Sprited Icons in a Vector Layer

Axel Kittenberger axkibe at gmail.com
Wed Oct 31 03:27:44 PDT 2012


Hi!

How do I add an Icon as Sprite in a Vector Layer?

This is very possible on Markers Layers through the use of a CSS referal.
However, I want to add one Marker to Layer that otherwise would be a Vector
Layer, as well I read the Vector Layer should be eitherway the prefered way
to base new code on.

I found some code with  feature.style = { externalGraphic : ... } to add
Icons on a Vector Layer, but how do I add a boundingbox to that graphic, so
I can use it as part of a sprite? Preferable I'd have a CSS referal again,
a CSS class to be used is what the existing sprite generator gives me, and
has been used with the Markers Layer so far.

- Axel
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/openlayers-users/attachments/20121031/d08fc949/attachment.html>


More information about the Users mailing list