Cruisers Forum
 


Reply
  This discussion is proudly sponsored by:
Please support our sponsors and let them know you heard about their products on Cruisers Forums. Advertise Here
 
Thread Tools Search this Thread Rate Thread Display Modes
Old 02-12-2024, 12:06   #1
Registered User
 
Cheyne's Avatar

Join Date: May 2018
Location: Urbanna, VA
Boat: Lagoon 380 PC Limited Edition
Posts: 443
Hide Way Point Names

Is there a way to hide way point names without having to do it each time I open up a route that I have imported. I want the route, but don't want to see the way point names. So far what I have found is to right click on the route and then hide the names, but I would rather they were hidden by default.

Thanks

Cheyne
Cheyne is offline   Reply With Quote
Old 03-12-2024, 02:27   #2
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,419
Re: Hide Way Point Names

Cheyne..
If I, when the cursor is located on the route, by the canvas right click menu select "Hide Waypoint Names" it's saved and the names are not shown at next OCPN start.
Is it not the same for you? I've O v 5.10.2 on Windows
Hakan is offline   Reply With Quote
Old 03-12-2024, 06:02   #3
Registered User
 
Cheyne's Avatar

Join Date: May 2018
Location: Urbanna, VA
Boat: Lagoon 380 PC Limited Edition
Posts: 443
Re: Hide Way Point Names

I'm running 5.10.2 on Win11. While I can hide a route waypoint name and they stay hidden on the next launch when I open another route I have to hide the name for the new route. What I'm after is never having the route names show up unless I right click and unhide them. On the waterways I'm running on with the names not hidden it looks like trash at best. On the rivers I might have 30 waypoints in just a quarter mile to get around a corner.

Cheyne
Cheyne is offline   Reply With Quote
Old 04-12-2024, 04:49   #4
Registered User
 
Antipole's Avatar

Join Date: Oct 2019
Location: Emsworth, UK
Boat: Alubat Ovni 395
Posts: 329
Re: Hide Way Point Names

You can do this with a script in the JavaScript plugin.

Below is a sample script to get you going. You can develop this for your exact requirements.

What this script does
  1. Works through each route in OpenCPN
  2. Works through each point in a route
  3. Sets its isNameVisible attribute to false
  4. Makes a note it has processed this route by appending the script name to the route description
  5. Updates the route in OpenCPN
By marking which routes it has updated, the script can be run repeatedly and it will leave alone those that it has already processed. So if you subsequently make a mark visible again, it will be left alone.

This script compiles OK but I have not tested it further as I do not want to mess with my 379 routes.

Code:
scriptName = "Hide Names";
routeGuids = OCPNgetRouteGUIDs();
updateCount = 0;

for (r = 0; r < routeGuids.length; r++){	// for each route
	route = OCPNgetRoute(routeGuids[r]);
	if (route.description.indexOf(scriptName) >= 0) break;	// have done this one
	for (p = 0; p < route.waypoints.length; p++){ // for each point in route
		route.waypoints[p].isNameVisible = false; // hide name
		}
	route.description += (" " + scriptName);
	updateCount++;
	OCPNupdateRoute(route);
	}
print(updateCount, " routes updated; ",
		routeGuids.length-updateCount, " routes unchanged\n");
__________________
If all else fails, read the instructions.
Antipole is offline   Reply With Quote
Old 04-12-2024, 05:10   #5
Registered User
 
Cheyne's Avatar

Join Date: May 2018
Location: Urbanna, VA
Boat: Lagoon 380 PC Limited Edition
Posts: 443
Re: Hide Way Point Names

I'm looking for a check box to hide waypoint names. I litterally have no idea what you just posted. Thanks for posting as it might help someone.

Cheyne
Cheyne is offline   Reply With Quote
Old 04-12-2024, 05:14   #6
Registered User
 
Antipole's Avatar

Join Date: Oct 2019
Location: Emsworth, UK
Boat: Alubat Ovni 395
Posts: 329
Re: Hide Way Point Names

Quote:
Originally Posted by Cheyne View Post
I'm looking for a check box to hide waypoint names. I litterally have no idea what you just posted. Thanks for posting as it might help someone.

Cheyne
It is not difficult. Install the JavaScript plugin, copy the script into the script pane and press run. It will do what you want.
If you load another one of these routes, just run the script again.
__________________
If all else fails, read the instructions.
Antipole is offline   Reply With Quote
Old 04-12-2024, 05:16   #7
Registered User
 
Cheyne's Avatar

Join Date: May 2018
Location: Urbanna, VA
Boat: Lagoon 380 PC Limited Edition
Posts: 443
Re: Hide Way Point Names

We would have to start with what is Javascript. I'm assuming some kind of programming thing. This isn't a science experiment. Just trying to replace Navionics with OpenCPN and in Navionics the waypoints don't show names.

Cheyne
Cheyne is offline   Reply With Quote
Old 04-12-2024, 08:17   #8
Registered User

Join Date: Nov 2012
Location: Orust Sweden
Boat: Najad 34
Posts: 4,419
Re: Hide Way Point Names

Cheyne...

Try this to set "no name" as default for new WPs:
Attached Thumbnails
Click image for larger version

Name:	WP_noname.jpg
Views:	81
Size:	348.3 KB
ID:	296462  
Hakan is offline   Reply With Quote
Old 04-12-2024, 08:20   #9
Registered User
 
Cheyne's Avatar

Join Date: May 2018
Location: Urbanna, VA
Boat: Lagoon 380 PC Limited Edition
Posts: 443
Re: Hide Way Point Names

Let me give that a try. Thanks.,

Cheyne
Cheyne is offline   Reply With Quote
Old 08-12-2024, 00:53   #10
Registered User
 
rooiedirk's Avatar

Join Date: Aug 2010
Location: Netherlands
Boat: Oneoff
Posts: 524
Re: Hide Way Point Names

There is no checkbox to easy switch visibility. No idea of the java script will work, but you might also:
In the route manager export the route. You get a 'gpx' file from the route. Make somewhere a backup copy of this file!!
Open the route.gpx in an editor, will look something like
Code:
......

<rtept lat="53.365889227" lon="6.066872774">
      <time>2024-12-08T07:24:51Z</time>
      <name>002</name>
      <sym>empty</sym>
      <type>WPT</type>
      <extensions>
        <opencpn:guid>327cc6e0-de89-4284-9f64-7229699e9b8b</opencpn:guid>
        <opencpn:auto_name>1</opencpn:auto_name>
        <opencpn:viz_name>1</opencpn:viz_name>
        <opencpn:arrival_radius>0.050</opencpn:arrival_radius>
        <opencpn:waypoint_range_rings visible="false" number="0" step="1" units="0" colour="#FF0000" />
        <opencpn:scale_min_max UseScale="false" ScaleMin="2147483646" ScaleMax="0" />
      </extensions>
    </rtept>
    <rtept lat="53.381829968" lon="6.076092956">
      .......
Then do a search/replace on the "<opencpn:viz_name>1</opencpn:viz_name>" part and change the '1' into '0'. Save the file and import in OpenCPN. Dont forget to delete the 'old' route in O otherwise you endup with double routes.


If there are no lines in your gpx with '<opencpn:viz_name>1</opencpn:viz_name>' you may insert them.
A small example of a route with only one waypoint name visible.
Attached Thumbnails
Click image for larger version

Name:	Screenshot_20241208_085359.png
Views:	54
Size:	7.8 KB
ID:	296572  
__________________
Navigation is know where you are and what to do to get where you want.
But also: Know where you don't want to be and what to do to don't get there.
rooiedirk is offline   Reply With Quote
Old 08-12-2024, 01:07   #11
Registered User
 
rooiedirk's Avatar

Join Date: Aug 2010
Location: Netherlands
Boat: Oneoff
Posts: 524
Re: Hide Way Point Names

As alternative but more cumbersome way you can change single routepoints.
Open route manager-->Properties. Then in properties window right click on routepoint to change. Go to extended waypoint properties and there is your checkbox
Attached Thumbnails
Click image for larger version

Name:	Screenshot_20241208_090333.png
Views:	52
Size:	256.0 KB
ID:	296573  
__________________
Navigation is know where you are and what to do to get where you want.
But also: Know where you don't want to be and what to do to don't get there.
rooiedirk is offline   Reply With Quote
Old 08-12-2024, 04:36   #12
Registered User
 
Cheyne's Avatar

Join Date: May 2018
Location: Urbanna, VA
Boat: Lagoon 380 PC Limited Edition
Posts: 443
Re: Hide Way Point Names

Both of those are horrible suggestions. What I want is a way to never see the names without any intervention on my part. The minute you said open a file and edit it you lost me.

Cheyne
Cheyne is offline   Reply With Quote
Old 14-12-2024, 05:30   #13
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 18,123
Images: 2
Re: Hide Way Point Names

So why not make a feature request or RFE (Request for Enhancement) with some detail about what you would like for and where in the menu system you think the control should be?


This kind of help might eventually yield a resolution for you.
Alternatively, the Javascript plugin might provide a quicker solution, but the Plugin API may not be prepared for that kind of control.



Quote:
Originally Posted by Cheyne View Post
Both of those are horrible suggestions. What I want is a way to never see the names without any intervention on my part. The minute you said open a file and edit it you lost me.

Cheyne
rgleason is offline   Reply With Quote
Old 14-12-2024, 19:02   #14
Registered User

Join Date: Aug 2009
Location: Onboard, currently cruising in SE Asia
Boat: St. Francis 44 Mk II (Catamaran)
Posts: 257
Send a message via Skype™ to SoggyPaws
Re: Hide Way Point Names

Interesting.
Windows 10, OpenCPN 5.10.2-0, I am not seeing waypoint names, either in a route I just now created or in routes I have created before.
I imported a route created in 2021, and the route point names don't show.
But I imported a route created in 2015, and the route point names DO show.
Ahh, but looking more closely at the route points (by opening the gpx file in a text editor), the difference is, the 2015 route had
<opencpn:viz_name>1</opencpn:viz_name>
on each of the route points. Whether this was done by my friend who created that route, or was the default in a much earlier version of OpenCPN, I don't know.
But currently, creating a new route, on my system, the default is that route point names are not visible.
SoggyPaws is offline   Reply With Quote
Old 15-12-2024, 07:06   #15
Registered User
 
rgleason's Avatar

Join Date: Mar 2012
Location: Boston, MA
Boat: 1981 Bristol 32 Sloop
Posts: 18,123
Images: 2
Re: Hide Way Point Names

Tony has the simple answer I think. Use Javascript plugin and his script.
See Post 6 https://www.cruisersforum.com/forums...ml#post3954657
rgleason is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
Boat Names...point of view hamburking Fishing, Recreation & Fun 111 20-11-2016 22:17
Would You Ever Hide Your Ensign? Nostrodamus General Sailing Forum 86 03-09-2012 23:02
Developers: Need Help on v2.5.0 to Change Fade Tool Bar to Hide manuprenlair OpenCPN 19 08-06-2012 05:12
Hurricane season: 2 year planned trip to the bahamas and the carib, where do we hide? aimlesswanderer Our Community 14 18-06-2011 09:03
Point No Point Lighthouse For Sale TaoJones Atlantic & the Caribbean 10 25-11-2007 08:14

Advertise Here


All times are GMT -7. The time now is 23:57.


Google+
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
Social Knowledge Networks
Powered by vBulletin® Version 3.8.8 Beta 1
Copyright ©2000 - 2025, vBulletin Solutions, Inc.

ShowCase vBulletin Plugins by Drive Thru Online, Inc.