Opened 13 years ago
Closed 12 years ago
#1834 closed enhancement (fixed)
Measure tool should provide a unit selection option
Reported by: | trevorwekel | Owned by: | trevorwekel |
---|---|---|---|
Priority: | low | Milestone: | 2.4 |
Component: | AJAX Viewer | Version: | 2.2.0 |
Severity: | trivial | Keywords: | measure, haspatch |
Cc: | External ID: |
Description
The buffer tool in the Ajax viewer allows the end user to specify the units for the buffer region. The measure tool should do the same. Some users may find measurement by only miles and kilometers too restrictive.
Attachments (2)
Change History (9)
by , 13 years ago
Attachment: | measurepatch.patch added |
---|
comment:1 by , 13 years ago
See attached patch measurepatch.patch for selecting the measurement units as part of the measure dialog. It was developed against the open source 2.2 branch and should be applicable to trunk.
comment:2 by , 13 years ago
Keywords: | haspatch added |
---|
comment:3 by , 13 years ago
Milestone: | → 2.4 |
---|
comment:4 by , 13 years ago
Martin Morrison suggested that I add us survey feet to the patch. See measurepatch2.patch. I have tested it with .Net. If anyone has a php or java setup running, please try it out and let me know if I broke something (bit busy this week to perform three platform testing).
comment:5 by , 13 years ago
Hi Trevor, I have tested your patch on both PHP and JSP, they all worked well. when do you plan put this enhancement to the trunk? another thing is that when you change the "Measure Units" after some points drawn on the map, the total will not be changed. Would you mean to do this?
comment:6 by , 13 years ago
There is one small bug I've found in measureui.templ
The SetUnits() function has the unit assignment in the wrong order. The line
units = GetParent().GetMapFrame().IsEnglishUnits()? "km": "mi";
should be the other way round.
units = GetParent().GetMapFrame().IsEnglishUnits()? "mi": "km";
This ensures the default unit selection in the Measure UI lines up with whatever choice was set in the viewer options.
Other than that, the patch looks fine
Patch for measure tool enhancement