[OpenLayers-Trac] [OpenLayers] #1588: (OpenLayers.Layer.Vector) drawFeature does not function correctly when feature.style is set.

OpenLayers trac at openlayers.org
Tue Jun 17 13:12:41 EDT 2008


#1588: (OpenLayers.Layer.Vector) drawFeature does not function correctly when
feature.style is set.
-------------------------+--------------------------------------------------
  Reporter:  openlayers  |       Owner:        
      Type:  bug         |      Status:  closed
  Priority:  minor       |   Milestone:        
 Component:  general     |     Version:  2.6   
Resolution:  invalid     |    Keywords:        
     State:              |  
-------------------------+--------------------------------------------------
Changes (by ahocevar):

  * status:  new => closed
  * resolution:  => invalid

Comment:

 I assume that you are referring to the case when you have a feature.style
 or layer.style set and pass a renderIntent to the optional style property
 of Layer.Vector.drawFeature. This is intended behaviour. Either you use
 the "old school" styling with style properties on features and/or layers,
 or you use the new styling framework with !StyleMap and renderIntent.

 If you have a feature.style set, you can only override that by also
 passing a style (not a renderIntent!) as second argument to
 layer.drawFeature. So if you work with layer- or feature based styles, you
 have to take care that components like Control.!SelectFeature also have
 style properties (in that case selectStyle) set.

 Please feel free to reopen this ticket in case I'm missing something here.

-- 
Ticket URL: <http://trac.openlayers.org/ticket/1588#comment:1>
OpenLayers <http://openlayers.org/>
A free AJAX map viewer


More information about the Trac mailing list