[Script] WME Cities Overlay

WME Cities Overlay

Version: 2018.06.26.01

Greasyfork: https://greasyfork.org/en/scripts/40837-wme-cities-overlay

Description: This will display the boundaries for incorporated and CDP places across the United States. The original KML files were pulled from the Census Bureau, but some states have elected to modify them by adding more townships in order to match how their state sets the cities for segments/Places.

How it works: all of the KML files are hosted in the script’s github repository and when you cross state borders the new state’s KML file will be loaded and the map will be updated to reflect the new city outlines. When you are focused on a city that city will be highlighted (if you have the option enabled) in a different color so it is easier to see that city’s borders when there are other cities/townships/CDPs bordering the city.

Along with SM approval all states are welcome to modify their KMLs as they see fit, whether it be to add polygons or use a different, more accurate source. I will accept pull requests for the modifications or if you want to send me the modified file I will update the repository. If any non-SM sends modifications I will not accept the pull request or update with a modified file until a SM approves the changes.

Script github: https://github.com/WazeDev/WME-Cities-Overlay

US KML files: https://github.com/WazeDev/WME-Cities-Overlay/tree/master/KMLs/US

MX KML files: https://github.com/WazeDev/WME-Cities-Overlay/tree/master/KMLs/MX

Changelog:

2018-06-26 - 2018.06.26.01 - Added manual and automatic updating of state files from the server
2018-06-22 - 2018.06.22.01 - added saving KML files to the browser database to prevent the files from downloading on every WME load

Just so I’m clear, does this replace WME US Government Boundaries?

No, this does not replace the WME US Government Boundaries script.

Update released! 2018.04.30.04

Support for Mexico added! State/city KMLs were provided by Carloslaso. Thanks Carlos!

Thanks señor Justin! :slight_smile:

I have not run into it yet, but does the color of the highlighted city match any of the WME city layer polygon colors? Also Thanks for this amazing script! :smiley:

No idea - the only time I have that layer enabled is when I am modifying city names :slight_smile:

Thanks for this script! I usually run with the Cities layer on because I like to be able to easily tell when I cross city limits on the map. The colors in that layer were hard with some places; this script makes it appear much clearer. I like that it will highlight the limits of the city the map is centered on. One suggestion I’d love to see added is a dynamic city name label, similar to what exists in the WME US Govt Boundaries layer with the county name and ZIP code. I think that would make it a little easier to visually see especially when editing in areas where city limits run up together.

Thanks for the suggestion! The city name is also displayed in the top bar. I prefer this to a dynamically displayed name since it is one less thing that can obstruct your view

Justin,

This is not a knock on your script, which is quite helpful, but it should be noted that the Census Bureau’s shape files are not 100% accurate. Where available, a state or local government’s parcel boundaries (in GIS Layers) will often give a more precise location of the city boundary than the census files will.

This is true, and this is one of the reasons that I posted this to SMs several times first and let them know they were free to modify the KMLs as they desire but only one opted to do so. As I stated in the initial post some states have opted to modify the KMLs, and they are still available to do so. I will post a link to the github in the first post so SMs can more easily access the repository and KMLs. As long as the KMLs stick to only displaying city information (so we are not mixing the purpose of various scripts), they are free to modify as they see fit and either 1) send me a pull request to update, or 2) send me the modified KML file to update the respository with.

Would it be possible to add a feature, such that if I hover inside the polygon of a city, a popup shows the city name? I find that it is distracting to zoom way out in order to determine which city’s polygon I’m actually inside.

I think that would be useful in areas where several small cities are close together.

It might be useful to be able to disable with a checkbox as well.

Thanks

The city name is already displayed in the title bar.

maybe i’m just not familiar with how it works. If I keep WME on the same location and zoom in from 2000 foot scale to like 200 foot scale, three different city names display there.

ok. i see how it works. I think.

Hey Justin,

Just duplicating my request to include Australia. We have a few people who aren’t on discord.

Ituajr’s been on top of our suburbs list. So he is probably the person that can find the boundary files for us.

If you let him know what you need, he can probably find it.

Hey Geoff and Justin,

Did some searching to try and find a reliable, central and authoritative source which offers flexible output which might help Justin out. This one seems to meet all of the requirements!

Judging by the label though, the data may be old?

A sample of data overlayed on another map:

Each state appears to have its own data source which is much more current; I could see updates to data in the current year in the state of NSW dataset I looked at.

NSW Administrative Boundaries - Suburb
http://maps.six.nsw.gov.au/arcgis/rest/services/public/NSW_Administrative_Boundaries/MapServer/0

ACT Division Boundaries
http://data.actmapi.act.gov.au/arcgis/rest/services/data_extract/Land_Administration/MapServer

If this is helpful, let me know and we’ll go look up the other states.

I looked at the licensing requirements and most require attribution. Can your script do that? For example:

NSW:

It would be up to Waze editors to ensure they do not copy any of the data and not you, so this could work.

Example of state NSW data:

You know us so well :wink:

What is needed to settle this debate, where is the discussion, and how do we come to a conclusion? I also think we can reach a conclusion on a state by state basis as well, which will allow us to progress forward sooner and allow other states to come to their own decisions.

Checked with Justin who said attribution is no problem at all. :slight_smile:

Yes, “he” is well aware.