[OpenLayers-Users] drawing style

Lehtonen, Mika mika at digikartta.net
Wed Feb 25 14:48:16 EST 2009


I prefer number two. That way the vector you are drawing would differ 
from the old sketches. The idea of  having users to choose from some 
assortment seems reasonable (and fair). Also users could suggest some 
own option. The worst case is to leave yellow thick line.

- mika -

Tim Schaub kirjoitti:
> Hey-
>
> So, we've long defined a "temporary" style for vector features.  This is 
> a symbolizer that is used to create an OpenLayers.Style object keyed by 
> the "temporary" rendering intent in the default StyleMap given to all  
> vector layers.
>
> http://trac.openlayers.org/browser/trunk/openlayers/lib/OpenLayers/Feature/Vector.js#L378
>
> This is a symbolizer that was put together without much thought.  It is 
> a garish yellow line, 4 pixels wide.  Nobody probably saw it used before.
>
> I just put in a change that passes the style associated with the 
> temporary rendering intent to the sketch handlers.  The effect is that 
> this default symbolizer is now used when drawing new sketches.
>
> So, if you didn't explicitly change your temporary feature style before, 
> you used to get the partially transparent orange.  Now you get thick 
> yellow strokes.
>
> This makes things a bit uglier by default (in my opinion).  We've got a 
> couple options:
>
> 1) Make the temporary style the same as the default style.  This would 
> give people what they had before (partially transparent orange sketches).
>
> 2) Make the temporary style something else.  This would change the look 
> of applications where people were using the defaults.  (And we could 
> post some options and for people to weigh in on.)
>
> Any opinions?
>
> Tim
>
> See the temporary yellow style here:
> http://openlayers.org/dev/examples/select-feature.html
>
>
>   



More information about the Users mailing list