From 9a818b3a490780de0ff80bc914455d2c850be2e2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Stephan=20B=C3=B6sch-Plepelits?= Date: Tue, 5 Jun 2018 21:28:15 +0200 Subject: [PATCH] Buildings: create a real 'figure-ground diagram' as sub category of buildings --- buildings-figure-ground.json | 37 ++++++++++++++++++++++++++++++++++++ buildings.json | 34 +++++---------------------------- 2 files changed, 42 insertions(+), 29 deletions(-) create mode 100644 buildings-figure-ground.json diff --git a/buildings-figure-ground.json b/buildings-figure-ground.json new file mode 100644 index 0000000..63d23c7 --- /dev/null +++ b/buildings-figure-ground.json @@ -0,0 +1,37 @@ +{ + "type": "overpass", + "name": { + "de": "Schwarzplan", + "en": "Figure-ground diagram" + }, + "query": { + "16": [ + "(", + " way[building];", + " relation[building];", + ")" + ] + }, + "feature": { + "markerSymbol": null, + "priority": [ + "{% set p = 100 %}", + "{% if tags.name %}{% set p = p - 10 %}{% endif %}", + "{% if tags.amenity %}{% set p = p - 1 %}{% endif %}", + "{% if tags.historic %}{% set p = p - 1 %}{% endif %}", + "{% if tags.culture %}{% set p = p - 1 %}{% endif %}", + "{% if tags.highway %}{% set p = p - 1 %}{% endif %}", + "{% if tags.railway %}{% set p = p - 1 %}{% endif %}", + "{% if tags.aeroway %}{% set p = p - 1 %}{% endif %}", + "{% if tags.amenity %}{% set p = p - 1 %}{% endif %}", + "{% if tags.tourism %}{% set p = p - 1 %}{% endif %}", + "{{ p }}" + ], + "style": { + "width": "0", + "color": "#000000", + "fillColor": "#000000", + "fillOpacity": "1" + } + } +} diff --git a/buildings.json b/buildings.json index 17b49fa..94bb4a9 100644 --- a/buildings.json +++ b/buildings.json @@ -1,38 +1,14 @@ { - "type": "overpass", + "type": "index", "name": { "de": "Gebäude", "en": "Buildings", "fr": "Bâtiments", "pt-br": "Edificações" }, - "query": { - "16": [ - "(", - " way[building];", - " relation[building];", - ")" - ] - }, - "feature": { - "markerSymbol": null, - "priority": [ - "{% set p = 100 %}", - "{% if tags.name %}{% set p = p - 10 %}{% endif %}", - "{% if tags.amenity %}{% set p = p - 1 %}{% endif %}", - "{% if tags.historic %}{% set p = p - 1 %}{% endif %}", - "{% if tags.culture %}{% set p = p - 1 %}{% endif %}", - "{% if tags.highway %}{% set p = p - 1 %}{% endif %}", - "{% if tags.railway %}{% set p = p - 1 %}{% endif %}", - "{% if tags.aeroway %}{% set p = p - 1 %}{% endif %}", - "{% if tags.amenity %}{% set p = p - 1 %}{% endif %}", - "{% if tags.tourism %}{% set p = p - 1 %}{% endif %}", - "{{ p }}" - ], - "style": { - "width": "1", - "color": "#000000", - "fillColor": "#000000" + "subCategories": [ + { + "id": "buildings-figure-ground" } - } + ] }