Skip to main content

Mapbox streets very dark

Answered

Comments

16 comments

  • Gilles Subias

    0
  • Brian Lawson Community moderator

    Is this what you are looking for?

    The map color is hard-coded into the HTML file that displays the map. How good are your HTML editing skills and how comfortable are you with making changes to the code used by the program? This is in the program's Application Support folder, not your user data. It is a simple ASCII text file so it is easy to edit with a Text Editor not a Word Processor!

    I'll give you some instructions and possibly just a replacement HTML file to make it easier later if you like.

    0
  • Brian Lawson Community moderator

    BTW, it is also an easy fix to change the default latitude and longitude coordinates to any location you like. Mine goes to St George where I live. 😃

    0
  • Gilles Subias

    Oh yes ! I really prefer the map as yours, not dark as mine (selecting streets option); and second changing default location would help ! (I did this change some years ago, but I forgot the way to fix it, sure it yet was you who helped then !). I'm not in hurry, so don't waste too much time for me.

     

    0
  • Brian Lawson Community moderator

    No problem. I keep mine in dark version. I changed it to test my theory and give you an illustration. 😀

    The file you want to edit is at

    Macintosh HD/Library/Application Support/ON1/ON1 Photo RAW 202x/WebContent/MapView/MapViewMainMac.html

    I made a copy that I put in my Pictures folder which I use to make my test changes. It also provides a backup as every new update or Upgrade will put a new WebContent folder in place and you will loose your modifications. Now I just copy from there back to the program's folder and I'm back in business.

    Here is what you want to edit.

    For the Streets view color search for the line  

    map.setStyle('mapbox://styles/mapbox/dark-v10');

    Change dark-v10 to light-v10

    For the default location look for

    center: [-122.74753, 45.409199], 

    Change it to your preferred Longitude, Latitude. Note the reversal of the normal order. There is a line right above it where the dark style is also set. You might want to change that as well.

    THE WARNING COMES AFTER THE SPELL!

    Duplicate the lines you are going to edit and put // at the beginning of them to turn them into comments so you retain the original code. Make the changes to the other set. Save your work.

    Now go to the program's WebContent/WebView folder and Duplicate the original file for a backup then drag your version to replace what the program will use.

    Launch PR and you should be in business. If things don't work, trash your edited copy and rename the duplicate to recover. Again, PR has to be restarted before it will recognize the changes.

    0
  • Gilles Subias

    Great ! I only changed the mapstreets color dark > light, it's ok.

    Later on or tomorrow I'll try to change the default L&l location.

    Many thanks ;-))

    0
  • Gilles Subias

    Hello again !

    So I did all ok, but the problem remains with location: browse mode, film strip, choose one picture previously  geotagged and pined in map view, ok, but if I go to another picture not geotagged map shows US map ?

    Center (I changed it for France Lat & Lon) right for previous geotags but not for create new ones > jump to USA.

    Some more code to add ?

    0
  • Brian Lawson Community moderator

    One my system, when I stay in Map view and use the Arrow keys or click in the Filmstrip to advance to a new photo which does not have any GPS coords the map view does not change. Only the pin marker gets removed from the map.

    There aren't any other code changes needed. The line we modified sets a variable to define the default location for when the Map View is opened and there is no GPS coord for any selected image. That variable is referenced whenever the program wants to change to those coords. No more coords are hard coded anywhere. After that all bets are off, sorry.

    0
  • Gilles Subias

    Oops, sorry; it's when I click on the film strip on an empty place at the end of the strip ! Return to Portland 😏

    0
  • Brian Lawson Community moderator

    That is not surprising since you now have no photo selected at all. I have not analyzed the code in depth to understand all of it. I just found what I needed to solve the problem of going where I want with at least one selected photo.

    I've got to go out for a while but I'll take another look later when I return.

    0
  • Gilles Subias

    Don't worry, it's a real small problem !

    0
  • Ade

    Hello Brian Lawson,

    brilliant, I've followed your instructions and now when I go to map view it is my home area. thanks very much.

    I've been asking Support to add the ability to change the map location since i started with ON1 2021. Even submitted a request when I was beta testing 2024. Always came back as nice to have.

     

    0
  • Brian Lawson Community moderator

    And it would be such a simple thing to add to the Preferences. I could do it in an hour and I've never even see the code!

    0
  • Ade

    Ah yes I was going to add a comment along those lines but changed my mind. I agree as having spent many years writing software before retiring I'm sure it is not an onerous task.

    Portland Oregon is probably a very nice place but I live 4000 miles away and would much rather have the map centered around my home location. So your 'hack' is great. Many thanks again.

    0
  • Gilles Subias

    I suppose ON1 pays a licence for have Mapbox in Photo Raw and allow their user to use this service, so the company location appears first; when we users add our photos coords/gps etc, the way is user > ON1 > Mapbox (or OSM) the return Mapbox > ON1 > user ( a long travel in micro seconds !); so we can't avoid the Portland location when we click on an empty part of the film strip.

    Right ?

    0
  • Brian Lawson Community moderator

    I don't know how the program is handling what happens when no photo has been selected. I have to assume it is passing in to the Mapbox code some kind of coordinate and in the absence of a photo coord they are substituting their own.

    0

Please sign in to leave a comment.