Browse Source

railway-infrastructure: support railway=razed

railway-rails
parent
commit
8757edf11e
  1. 19
      railway-infrastructure.yaml

19
railway-infrastructure.yaml

@ -28,7 +28,7 @@ feature:
{% set width = 2 %} {% set width = 2 %}
{% if tags.service == 'yard' or tags.service == 'siding' or tags.service == 'spur' or tags.service == 'crossover' %} {% if tags.service == 'yard' or tags.service == 'siding' or tags.service == 'spur' or tags.service == 'crossover' %}
{% set width = 1 %} {% set width = 1 %}
{% elseif tags.railway in ['rail', 'narrow_gauge', 'abandoned', 'disused'] %}
{% elseif tags.railway in ['rail', 'narrow_gauge', 'abandoned', 'disused', 'razed'] %}
{% if tags.usage in ['main', 'branch'] %} {% if tags.usage in ['main', 'branch'] %}
{% set width = 3 %} {% set width = 3 %}
{% else %} {% else %}
@ -85,7 +85,7 @@ feature:
<line x1='2' x2='7' y1='2' y2='13' style='stroke-width: 2; stroke: #000000; stroke-linecap: round;'/> <line x1='2' x2='7' y1='2' y2='13' style='stroke-width: 2; stroke: #000000; stroke-linecap: round;'/>
<line x1='7' x2='2' y1='2' y2='13' style='stroke-width: 2; stroke: #000000; stroke-linecap: round;'/> <line x1='7' x2='2' y1='2' y2='13' style='stroke-width: 2; stroke: #000000; stroke-linecap: round;'/>
</svg> </svg>
{% elseif tags.railway not in [ 'rail', 'tram', 'subway', 'narrow_gauge', 'abandoned', 'disused' ] %}
{% elseif tags.railway not in [ 'rail', 'tram', 'subway', 'narrow_gauge', 'abandoned', 'disused', 'razed' ] %}
{{ markerPointer({})|raw }} {{ markerPointer({})|raw }}
{% endif %} {% endif %}
listMarkerSymbol: |- listMarkerSymbol: |-
@ -103,6 +103,7 @@ feature:
styles: |- styles: |-
{% if tags.bridge and tags.bridge != 'no' %}casing_bridge,{% endif %} {% if tags.bridge and tags.bridge != 'no' %}casing_bridge,{% endif %}
{% if const.color[tags.railway] %}casing,casing_layer,{% endif %} {% if const.color[tags.railway] %}casing,casing_layer,{% endif %}
{% if tags.railway in ['abandoned', 'disused', 'razed'] %}disused,{% endif %}
{% if tags.railway == 'narrow_gauge' %}default,narrow {% if tags.railway == 'narrow_gauge' %}default,narrow
{% else %}default {% else %}default
{% endif %} {% endif %}
@ -121,9 +122,9 @@ feature:
{% endif %} {% endif %}
opacity: 1 opacity: 1
dashArray: |- dashArray: |-
{% if tags.railway == 'rail' %}
{% elseif tags.railway == 'disused' %}1,5
{% if tags.railway == 'disused' %}1,5
{% elseif tags.railway == 'abandoned' %}1,7 {% elseif tags.railway == 'abandoned' %}1,7
{% elseif tags.railway == 'razed' %}1,9
{% endif %} {% endif %}
fill: |- fill: |-
{% if tags.railway == 'platform' %} {% if tags.railway == 'platform' %}
@ -144,6 +145,16 @@ feature:
{% elseif type == 'node' %} {% elseif type == 'node' %}
0 0
{% endif %} {% endif %}
style:disused:
width: |-
{{ width }}
zIndex: |-
{{ tags.layer|default(0) + 9.995 }}
color: white
opacity: 1
fill: false
style:casing: style:casing:
color: '#ffffff' color: '#ffffff'
pane: casing pane: casing

Loading…
Cancel
Save