[OpenLayers-Users] Custom OpenLayers Graphic Names with multiple vector features

Subhani Minhas subhaniminhas at gmail.com
Thu May 27 14:07:05 EDT 2010


Dear all, at present the graphic-name.html example from OL2.9 examples shows
us how to add a custom graphic name, as follows:

OpenLayers.Renderer.symbol.lightning = [0,0, 4,2, 6,0, 10,5, 6,3, 4,5, 0,0];
and
OpenLayers.Renderer.symbol.rectangle = [0,0, 4,0, 4,10, 0,10, 0,0];

1. My first question is , how can we add a feature with multiple
vector features, e.g. i found an example in geoext 0.7
http://dev.geoext.org/trunk/geoext/examples/renderer.html which can
draw multiple vectors in a single feature as following:

Geometry Well-Known Text : POLYGON((1 30, -33 10, -39 -21, 1 -41, 23
-22, 27 15, 1 30), (0 10, -14 0, -4 -24, 12 -8, 0 10))

How we can achieve the same in OL?

2. I want to achieve following: Once i add a vector layer feature on a
click event, the actual symbol is drawn above the point of click,
and it is connected with the point of click with a vector line. Also
when i drag the drawn vector feature the line's one end remains at the
point of click, while the other end is 'fastened' to the vector
feature. How this can be achieved in OL ?

Thanks in advance....

Any help will be welcome, especially if some code example can be given, thanks.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.osgeo.org/pipermail/openlayers-users/attachments/20100527/7c6b9e66/attachment.html


More information about the Users mailing list