Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Append secondary name glosses to labels depending on context #1053

Open
1ec5 opened this issue Apr 30, 2024 · 1 comment
Open

Append secondary name glosses to labels depending on context #1053

1ec5 opened this issue Apr 30, 2024 · 1 comment
Labels
enhancement New feature or request openmaptiles A change is needed in OpenMapTiles to support this

Comments

@1ec5
Copy link
Collaborator

1ec5 commented Apr 30, 2024

We gloss many kinds of labels with the name in the local language (#592), but this treatment is also useful for other names that a place might be known by. We could add these names to the label depending on the context. For example, a street name label could contain alt_name or official_name in smaller text in parentheses, at least at high enough zoom levels where these additional names wouldn’t collide out more important information. A place’s label could go from listing the nat_name to the reg_name to the loc_name as you zoom in progressively.

As we’ve done with the multilingual labels, we should try to keep the gloss from repeating the primary name in front of the gloss. This blog post demonstrates an approach to glossing peaks with alt_name, along with some deduplication. The style specification doesn’t give us many tools for deduplication, but we can at least perform case and diacritic folding.

For the most part, OpenMapTiles doesn’t expose these secondary name keys. The one exception is route names, which are now available in the transportation_name layer’s route_#_name properties. We might be able to rig something that glosses one of these names if we don’t have a shield for that route network.

@1ec5 1ec5 added enhancement New feature or request openmaptiles A change is needed in OpenMapTiles to support this labels Apr 30, 2024
@1ec5
Copy link
Collaborator Author

1ec5 commented Apr 30, 2024

Thanks to @n76 for cluing me into his prior work in this area.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request openmaptiles A change is needed in OpenMapTiles to support this
Projects
None yet
Development

No branches or pull requests

1 participant