anhtuanmai / osmdroid

Automatically exported from code.google.com/p/osmdroid
0 stars 0 forks source link

ScaleBar improvements #379

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
I've done some improvements to the ScaleBar which might be useful for others as 
well:
- adjust the displayed bar length so that it reflects a rounded distance 
starting with 1, 2 or 5 instead of displaying a fractional length. This works 
for metrical, imperial and nautical units.
- draw the bar centred around the given screen coordinates
- specify a different bar length (default is 1 inch)
- add a background to the bar to make it stand out better

All changes have been done in a way to maintain the previous behaviour if used 
in the same way.

The attached patch also contains the patch for issue 373.

Original issue reported on code.google.com by osei...@gmail.com on 17 Oct 2012 at 8:35

Attachments:

GoogleCodeExporter commented 8 years ago

Original comment by neilboyd on 18 Oct 2012 at 4:58

GoogleCodeExporter commented 8 years ago
This patch looks good so I am going to commit it with a few small changes. 
Thanks for the contribution!

Original comment by kurtzm...@gmail.com on 3 Jan 2013 at 6:20

GoogleCodeExporter commented 8 years ago
This issue was closed by revision r1137.

Original comment by kurtzm...@gmail.com on 3 Jan 2013 at 6:22