hungio / route-me

Automatically exported from code.google.com/p/route-me
0 stars 0 forks source link

Display a scale indicator in the MapView #94

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
Display an indication of the scale in the RMMapView.
This can be a simple line with the lenght in the real world below it (must be 
able to choose between 
km and mile)

Or it can be one line with the length in Miles (yards) above (or below) and the 
length in Kilometers 
(or meters) below (or above).

example attached.

Original issue reported on code.google.com by wou...@human-software.nl on 22 Mar 2009 at 7:28

Attachments:

GoogleCodeExporter commented 8 years ago

Original comment by Quazie on 23 Mar 2009 at 2:04

GoogleCodeExporter commented 8 years ago
A start on this problem would be some sample code to draw a scalebar in a 
layer, similar to the way 
SampleMap draws the map pan/zoom information. Getting scalebars right is, in 
general. difficult.

How long should it be? A 5 km scalebar is not appropriate at all zoom levels. 
Adaptive length is needed.

What are the major and minor subdivisions? E.g. 100 km scalebar, labels every 
25 km, unlabeled tickmarks 
every 5 km. You could leave this out completely in a first draft.

Units: kilometers, meters, statute miles, nautical miles, feet.

Where is it drawn? At what orientation? If my map is in landscape mode, might 
want scalebar vertically 
oriented at left or right edge.

Need to control transparency, color, font, font size.

Original comment by halmuel...@gmail.com on 23 Mar 2009 at 4:47

GoogleCodeExporter commented 8 years ago
The scalebar should be a simple:

|--------|   1 km
|------------|   1 mile

where the basic size should just be an adaptive length. Shouldn't be too 
complicated, we could hard-code a list 
of a number of lengths where one should always fit any zoom size.
I wouldn't bother with subdivisions.

Original comment by hasse...@gmail.com on 30 Mar 2009 at 7:39