Opened 15 years ago

Closed 13 years ago

#49 closed defect (wontfix)

MeasureTool Doc needs more information and/or sample

Reported by: woodbri Owned by:
Priority: major Milestone: 1.2.0
Component: documentation Version:
Keywords: Cc:

Description

The MeasureTool widgets must be manually added to the toolbar and they must by added to a resource too (even thought it has nothing to do with the chosen resource).

Also if the

I'm not sure what <graphicName>unknown</graphicName> is I think this may be the name of the icon, but I'm not sure what format it should be in for example:

  • measure_length
  • measure_length.png
  • /path/to/measure_length.png

and if it is a relative path or just a name, where the icon needs to be. Or if it has a totally different purpose.

<!-- WIDGETS -->
       <geoexttoolbar>
         <name>GeoExtToolbar</name>
         <options>
           <widgets>
             <widget>MeasureToolLength</widget>
             <widget>MeasureToolArea</widget>
           </widgets>
         </options>
       </geoexttoolbar>

       <measuretool>
           <name>MeasureToolLength</name>
           <options>
             <measuretype>Length</measuretype>
             <!--
             <geodesic>false</geodesic>
             <pointRadius>3</pointRadius>
             <graphicName>unknown</graphicName>
             <fillColor>white</fillColor>
             <fillOpacity>0.3</fillOpacity>
             <strokeWidth>1</strokeWidth>
             <strokeOpacity>1<strokeOpacity>
             <strokeColor>666666</strokeColor>
             <strokeDashstyle>dash</strokeDashstyle>
             -->
           </options>
       </measuretool>

       <measuretool>
           <name>MeasureToolArea</name>
           <options>
             <measuretype>Area</measuretype>
             <!--
             <geodesic>false</geodesic>
             <pointRadius>3</pointRadius>
             <graphicName>unknown</graphicName>
             <fillColor>white</fillColor>
             <fillOpacity>0.3</fillOpacity>
             <strokeWidth>1</strokeWidth>
             <strokeOpacity>1<strokeOpacity>
             <strokeColor>666666</strokeColor>
             <strokeDashstyle>dash</strokeDashstyle>
             -->
           </options>
       </measuretool>

<!-- RESOURCES -->
       <resource>
           <name>R_GMAP_BASE</name>
           <datastores>
               <datastore>DS_WMS_DEV4G_GMAP_BASE</datastore>
               <datastore>DS_TC_DEV4G_GMAP_BASE</datastore>
           </datastores>
           <widgets>
               <widget>GeoExtToolbar</widget>
               <widget>MeasureToolLength</widget>
               <widget>MeasureToolArea</widget>
           </widgets>
       </resource>

Change History (8)

comment:1 by woodbri, 15 years ago

Forgot to add a note about the fact that the map units need to be "m" or you need to set <geodesic>true</geodesic>.

comment:2 by woodbri, 15 years ago

Summary: MeasureTool Doc needs more information of sampleMeasureTool Doc needs more information and/or sample

comment:3 by woodbri, 15 years ago

OK, looks like graphicName refers to graphic symbol of a vector object symbol at vertices. The valid names are:

http://openlayers.org/dev/examples/graphic-name.html

While it is defined in the widget, it probably does not make sense to set it.

So it if someone wants to change the icon for the measure tool it would be helpful to document where and how. While I realize that this might be an OpenLayers or MapFish thing, the fact is the when you are using GP you are not using OL or MF, GP is using it and in fact even if you look at an OL example that information does not map directly to GP.

comment:4 by adube, 13 years ago

MeasureTool sample added in r1136. It doesn't show much features nor options, but at least it's a start after 22 months. Also :

The MeasureTool? widgets must be manually added to
the toolbar and they must by added to a resource too
(even thought it has nothing to do with the chosen resource). 

that's no longer the case. Static widgets no longer need to be linked to dummy resources.

comment:5 by adube, 13 years ago

The status of this ticket now depends on #292.

comment:6 by adube, 13 years ago

Milestone: 1.0.0

comment:7 by adube, 13 years ago

Milestone: 1.0.01.2.0

comment:8 by adube, 13 years ago

Resolution: wontfix
Status: newclosed

The widget was remade in #292. Its documentation is now complete.

Note: See TracTickets for help on using tickets.