Author Topic: Make destination offset and track width configurable in the map  (Read 188 times)

lbo

  • Full Member
  • **
  • Posts: 236
Two settings in the Map Panel are hard coded but not suitable for every user:

1. The offset of a newly created destination marker.

Currently, the code in maputility.js is
Code: [Select]
var dlat = lat + 0.0005;  // about 50 mthat's way too near if your object is at one km distance because you can't grab the marker easily. I currently patch it to lat + 0.005.

2. The track width

Unless you have a high dpi monitor, the current setting is too high. Using a 110PPI monitor, I patch the value to 3 pixels:

olmap.js: width: 3,
gmaps.js: var lineWeight = 3;

This has already been discussed in https://www.photools.com/community/index.php?topic=8233 started by Mees Dekker, supported by Carlo Didier, sinus and me. Screenshots are provided there.

Maybe you find a quick solution to incorporate configuration options for the small code changes I demonstrated above without blowing up the preferences dialog. Please don't spend "at least 1/2 to 1 developer day" as you estimated earlier.

Maybe you can use a text based configuration file?

Otherwise I keep patching the files which can be done in a half-automated way.

Oliver

lbo

  • Full Member
  • **
  • Posts: 236
Re: Make destination offset and track width configurable in the map
« Reply #1 on: March 27, 2019, 11:57:54 PM »
I forgot to mention that the destination marker offset might be calculated relative to the zoom level resp. window size, e.g. 1/4 window height. This way, no configuration is needed.

Carlo Didier

  • Super Hero
  • ****
  • Posts: 1233
Re: Make destination offset and track width configurable in the map
« Reply #2 on: March 28, 2019, 02:11:11 PM »
+1

jch2103

  • Super Hero
  • ****
  • Posts: 1682
Re: Make destination offset and track width configurable in the map
« Reply #3 on: March 28, 2019, 04:34:07 PM »
I forgot to mention that the destination marker offset might be calculated relative to the zoom level resp. window size, e.g. 1/4 window height. This way, no configuration is needed.
+1
John