[OpenLayers-Users] select display polygon length dimensions
Xavier Mamano (jorix)
xavier.mamano at gmail.com
Mon Aug 5 10:11:22 PDT 2013
Hi,
>... I also have a problem how to display polygon length dimensions if I
select the polygon.
Currently to measure existing features/geometries "DynamicMeasure.js" offers
no advantage over `OpenLayers.Control.Measure` :(
You need to write code and maybe to use non API methods `getBestArea` or
`getBestLength` of `OpenLayers.Control.Measure`.
>... function to get the coordinates of polygon's points
see `getVertices` method that you can call from any geometry:
http://dev.openlayers.org/releases/OpenLayers-2.13.1/doc/apidocs/files/OpenLayers/Geometry-js.html#OpenLayers.Geometry.getVertices
Regards,
Xavier
summer7310 wrote
> Hi,Xavier Mamano (jorix)
> thanks for your reply,that I also have a problem how to display polygon
> length dimensions if I select the polygon.I can not figure out which
> function to get the coordinates of polygon's points
> Xavier Mamano (jorix) wrote
>> Hi,
>>
>> Try
>> http://jorix.github.io/OL-DynamicMeasure/examples/measure-dynamic.html
>>
>> Note: leave "Segments to display" to blank to see all segments length.
>>
>> Regards,
>>
>>
>> Hello all,
>> I draw a polygon or a regular polygon,but when finish draw it .I
>> want to display the dimension of every polygon length,just like this
>> if any body know how to do it ,thank you very much.
> Quoted from:
> http://osgeo-org.1560.x6.nabble.com/How-to-display-polygon-length-dimensions-tp5069252p5069375.html
>
> _____________________________________
> Sent from http://osgeo-org.1560.x6.nabble.com
--
View this message in context: http://osgeo-org.1560.x6.nabble.com/select-display-polygon-length-dimensions-tp5070749p5070868.html
Sent from the OpenLayers Users mailing list archive at Nabble.com.
More information about the Users
mailing list