Skip to content
This repository has been archived by the owner on Jul 24, 2021. It is now read-only.

Grouping map features that share a top-level tag #3528

Closed
openstreetmap-trac opened this issue Jul 23, 2021 · 2 comments
Closed

Grouping map features that share a top-level tag #3528

openstreetmap-trac opened this issue Jul 23, 2021 · 2 comments

Comments

@openstreetmap-trac
Copy link

Reporter: stevage
[Submitted to the original trac issue database at 12.58am, Tuesday, 8th February 2011]

It's not currently possible to define a map feature covering multiple top-level tags, like railway=spur and railway=rail. As a result, we get a few too many entries in the feature list, when they would be better specified as sub-options.

@openstreetmap-trac
Copy link
Author

Author: stevage
[Added to the original trac issue at 12.55pm, Tuesday, 8th February 2011]

Actually, it is possible, it's just buggy: this matches ok:

It just stores the * literally as the value if nothing else is chosen.

Suggested enhancement:

  • don't store literal *'s
  • have a way of specifying more complex matches, perhaps

@openstreetmap-trac
Copy link
Author

Author: stevage
[Added to the original trac issue at 1.46pm, Tuesday, 8th February 2011]

I have implemented this in 25255, and welcome discussion on its merits. The final syntax/semantics I went with:

Means that any traffic_calming=* will be recognised, and the default value (unless set explicitly by the included dropdown) will be "yes"

If vmatch is not "*", it is interpreted as a regular expression, so this works:

or, more simply:

I think this is a useful extension, to solve a few peculiarities in the tagging scheme and to give us a bit of flexibility in decoupling the interface from the underlying tags. (With appropriate caution exercised...)

It doesn't quite solve the highway=proposed, proposed=..., but it's a step closer.

The same mechanism could also be used for elements of drop downs:

<choice value="muslim" vmatch="muslim|islamic" ...>

(Again, with appropriate caution...)

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

1 participant