Hi,

Is this something that might help you? It got into trunk just a few days 
ago.

#2312: Add label offset to styles
http://trac.openlayers.org/ticket/2312

Regards, Roald

Ringdahl Niklas wrote:
> Hi list.
>
> I would like to have more control on the label placement, using features with 
> labels on a vector layer. 
>
> I have several features added to a vector layer, rendering in SVG. I use the 
> style attribute "label" to set a label text for the point, and the 
> "labelAlign" attribute to set the alignment. But I don't feel that the 
> "labelAlign" property is doing what I want, I would like more control of 
> where my label ends up. So I looked into the SVG specification and the DOM 
> elements created by OpenLayers for my features and labels and found the "dx" 
> and "dy" attributes, which don't seem to be used in OpenLayers renderers. Is 
> this a design decision or is it just an area which noone have looked into?
>
> What I would like to do is to be able to set the SVG specific properties, 
> like "dx" and "dy" on the tspan element, to fine tune the placement of the 
> labels. Are there any more possibilities to control this than using the 
> "labelAlign" today? 
>
> If there is some kind of documentation of the label handling out there that I 
> haven't found, I would be happy to be pointed in the right direction.
>
> Thanks!
> - Niklas
> _______________________________________________
> Dev mailing list
> Dev@openlayers.org
> http://openlayers.org/mailman/listinfo/dev
>   

_______________________________________________
Dev mailing list
Dev@openlayers.org
http://openlayers.org/mailman/listinfo/dev

Reply via email to