Skip to content

Commit

Permalink
differentiate guidepost from general tourism=information display, add…
Browse files Browse the repository at this point in the history
… name and ele to guidepost if present
  • Loading branch information
nebulon42 committed May 22, 2018
1 parent 5e8292b commit 95d8b4b
Show file tree
Hide file tree
Showing 3 changed files with 76 additions and 7 deletions.
29 changes: 24 additions & 5 deletions amenity-points.mss
Original file line number Diff line number Diff line change
Expand Up @@ -313,11 +313,17 @@
marker-clip: false;
}

[feature = 'tourism_information'][zoom >= 17] {
marker-file: url('symbols/information.12.svg');
marker-placement: interior;
marker-fill: @amenity-brown;
marker-clip: false;
[feature = 'tourism_information'] {
[information != 'guidepost'][zoom >= 17],
[information = 'guidepost'][zoom >= 19] {
marker-file: url('symbols/information.12.svg');
[information = 'guidepost'] {
marker-file: url('symbols/guidepost.svg');
}
marker-placement: interior;
marker-fill: @amenity-brown;
marker-clip: false;
}
}

[feature = 'amenity_embassy'][zoom >= 17] {
Expand Down Expand Up @@ -1575,6 +1581,19 @@
text-placement: interior;
}

[feature = 'tourism_information'][information = 'guidepost'][zoom >= 19] {
text-name: "[name]";
text-size: @standard-font-size;
text-wrap-width: @standard-wrap-width;
text-line-spacing: @standard-line-spacing-size;
text-fill: darken(@landform-color, 30%);
text-face-name: @standard-font;
text-halo-radius: @standard-halo-radius;
text-halo-fill: @standard-halo-fill;
text-placement: interior;
text-dy: 11;
}

[feature = 'waterway_waterfall'] {
[zoom >= 13][height > 20],
[zoom >= 14][height > 10],
Expand Down
14 changes: 12 additions & 2 deletions project.mml
Original file line number Diff line number Diff line change
Expand Up @@ -1500,6 +1500,7 @@ Layer:
tags->'tower:construction' as "tower:construction",
tags->'tower:type' as "tower:type",
tags->'castle_type' as castle_type,
tags->'information' as information,
CASE WHEN shop IN ('supermarket', 'bag', 'bakery', 'beauty', 'bed', 'books', 'butcher', 'clothes', 'computer',
'confectionery', 'fashion', 'convenience', 'department_store', 'doityourself', 'hardware', 'fishmonger', 'florist',
'garden_centre', 'hairdresser', 'hifi', 'ice_cream', 'car', 'car_repair', 'bicycle', 'mall', 'pet',
Expand Down Expand Up @@ -1628,6 +1629,7 @@ Layer:
tags->'tower:construction' as "tower:construction",
tags->'tower:type' as "tower:type",
tags->'castle_type' as castle_type,
tags->'information' as information,
CASE WHEN shop IN ('supermarket', 'bag', 'bakery', 'beauty', 'bed', 'books', 'butcher', 'clothes', 'computer',
'confectionery', 'fashion', 'convenience', 'department_store', 'doityourself', 'hardware', 'fishmonger', 'florist',
'garden_centre', 'hairdresser', 'hifi', 'ice_cream', 'car', 'car_repair', 'bicycle', 'mall', 'pet',
Expand Down Expand Up @@ -2081,6 +2083,7 @@ Layer:
tags->'office' as office,
tags->'recycling_type' as recycling_type,
tags->'castle_type' as castle_type,
tags->'information' as information,
ref,
way_area,
CASE WHEN building = 'no' OR building IS NULL THEN 'no' ELSE 'yes' END AS is_building
Expand Down Expand Up @@ -2168,6 +2171,7 @@ Layer:
office,
recycling_type,
castle_type,
information,
ref,
way_area,
is_building
Expand Down Expand Up @@ -2227,7 +2231,9 @@ Layer:
access,
name,
CASE
WHEN "natural" IN ('peak', 'volcano', 'saddle') OR tourism = 'alpine_hut' OR amenity = 'shelter' THEN
WHEN "natural" IN ('peak', 'volcano', 'saddle')
OR tourism = 'alpine_hut' OR (tourism = 'information' AND tags->'information' = 'guidepost')
OR amenity = 'shelter' THEN
CASE
WHEN tags->'ele' ~ '^-?\d{1,4}(\.\d+)?$' THEN (tags->'ele')::NUMERIC
ELSE NULL
Expand All @@ -2250,6 +2256,7 @@ Layer:
tags->'office' as office,
tags->'recycling_type' as recycling_type,
tags->'castle_type' as castle_type,
tags->'information' as information,
ref,
NULL AS way_area,
CASE WHEN building = 'no' OR building IS NULL THEN 'no' ELSE 'yes' END AS is_building
Expand Down Expand Up @@ -2279,7 +2286,10 @@ Layer:
OR boundary IN ('national_park')
OR waterway IN ('dam', 'weir', 'dock'))
AND (name IS NOT NULL
OR (tags?'ele' AND ("natural" IN ('peak', 'volcano', 'saddle') OR tourism = 'alpine_hut' OR amenity = 'shelter'))
OR (tags?'ele' AND ("natural" IN ('peak', 'volcano', 'saddle')
OR tourism = 'alpine_hut'
OR (tourism = 'information' AND tags->'information' = 'guidepost')
OR amenity = 'shelter'))
OR (ref IS NOT NULL AND aeroway IN ('gate'))
)
) AS p
Expand Down
40 changes: 40 additions & 0 deletions symbols/guidepost.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 95d8b4b

Please sign in to comment.