Hi, [email protected] wrote: > The following code creates a Vector layer using a styleMap where I set > the style properties within some functions: > > > style = new OpenLayers.Style(template, {context: context}); > styleMap = new OpenLayers.StyleMap({'default': style, 'select': > {fillOpacity: 0.7}}); > > ... > ergebnisL = new OpenLayers.Layer.Vector('Suchergebnis', { > styleMap: styleMap > }); > > I´d like to calculate the graphicXOffset manually within the function > getXOffset. Therefore I would need to access some style properties > like graphicWidth of my current feature. I thought that it should work > using something like gW=feature.Vector.style.graphicWidth but > feature.Vector is empty ...
Try feature.style.graphicWidth instead of feature.Vector.style.graphicWidth. Regards, Andreas. -- Andreas Hocevar OpenGeo - http://opengeo.org/ Expert service straight from the developers. _______________________________________________ Users mailing list [email protected] http://openlayers.org/mailman/listinfo/users
