summaryrefslogtreecommitdiff
path: root/bin
diff options
context:
space:
mode:
authorNicki Dlugash <nicki@mapbox.com>2014-05-28 20:18:18 -0400
committerNicki Dlugash <nicki@mapbox.com>2014-05-28 20:18:18 -0400
commit46f7b3dd323f86ab937a454d039e1be4ecf60d77 (patch)
tree05485cf534095606c93e7835795c97ce275076fa /bin
parent984c1dd8d530140ddb3705147e912c08edf21714 (diff)
parent9698ac02cf277bcf7fe98718f210578f44eae626 (diff)
downloadqtlocation-mapboxgl-46f7b3dd323f86ab937a454d039e1be4ecf60d77.tar.gz
Merge pull request #267 from mapbox/even-more-label-styles
Even more label styles
Diffstat (limited to 'bin')
-rw-r--r--bin/style.js202
1 files changed, 123 insertions, 79 deletions
diff --git a/bin/style.js b/bin/style.js
index 8af9236ea3..cf59cc5f30 100644
--- a/bin/style.js
+++ b/bin/style.js
@@ -709,14 +709,6 @@ module.exports = {
"type": "text",
"enabled": 4
},
- "place_label_city_point": {
- "source": "outdoors",
- "layer": "place_label",
- "field": "type",
- "value": "city",
- "type": "point",
- "size": 4
- },
"place_label_city": {
"source": "outdoors",
"layer": "place_label",
@@ -761,17 +753,45 @@ module.exports = {
],
"text_field": "name",
"path": "horizontal",
- "fontSize": 14,
+ "fontSize": 18,
"feature_type": "point",
"type": "text"
},
- "road_label": {
+ "road_label_1": {
"source": "outdoors",
"layer": "road_label",
+ "field": "class",
+ "value": ["motorway","main"],
"text_field": "name",
"path": "curve",
"padding": 2,
- "fontSize": 13,
+ "fontSize": 18,
+ "feature_type": "line",
+ "type": "text",
+ "maxAngleDelta": 0.5
+ },
+ "road_label_2": {
+ "source": "outdoors",
+ "layer": "road_label",
+ "field": "class",
+ "value": ["street","street_limited"],
+ "text_field": "name",
+ "path": "curve",
+ "padding": 2,
+ "fontSize": 16,
+ "feature_type": "line",
+ "type": "text",
+ "maxAngleDelta": 0.5
+ },
+ "road_label_3": {
+ "source": "outdoors",
+ "layer": "road_label",
+ "field": "class",
+ "value": ["service","driveway","path"],
+ "text_field": "name",
+ "path": "curve",
+ "padding": 2,
+ "fontSize": 14,
"feature_type": "line",
"type": "text",
"maxAngleDelta": 0.5
@@ -1321,10 +1341,6 @@ module.exports = {
"bucket": "state_label"
},
{
- "name": "place_label_city_point",
- "bucket": "place_label_city_point"
- },
- {
"name": "place_label_city",
"bucket": "place_label_city"
},
@@ -1341,8 +1357,16 @@ module.exports = {
"bucket": "place_label_other"
},
{
- "name": "road_label",
- "bucket": "road_label"
+ "name": "road_label_1",
+ "bucket": "road_label_1"
+ },
+ {
+ "name": "road_label_2",
+ "bucket": "road_label_2"
+ },
+ {
+ "name": "road_label_3",
+ "bucket": "road_label_3"
},
{
"name": "contour_label",
@@ -1614,12 +1638,27 @@ module.exports = {
{"z": 8, "val": 1},
{"z": 12, "val": 2}
],
- "road_label_size": [
+ "road_label_1_size": [
"stops",
- {"z": 0, "val": 12},
+ {"z": 13, "val": 11},
{"z": 14, "val": 12},
{"z": 15, "val": 13},
- {"z": 22, "val": 13}
+ {"z": 16, "val": 14},
+ {"z": 17, "val": 16},
+ {"z": 18, "val": 18}
+ ],
+ "road_label_2_size": [
+ "stops",
+ {"z": 13, "val": 11},
+ {"z": 14, "val": 12},
+ {"z": 16, "val": 14},
+ {"z": 18, "val": 16}
+ ],
+ "road_label_3_size": [
+ "stops",
+ {"z": 15, "val": 10},
+ {"z": 16, "val": 12},
+ {"z": 18, "val": 14}
],
"fence_width": [
"stops",
@@ -2194,6 +2233,7 @@ module.exports = {
"country_label": {
"color": "country_text",
"stroke": "rgba(255,255,255,0.5)",
+ "strokeWidth": 0.4,
"size": "country_label_size"
},
"country_label_line": {
@@ -2208,7 +2248,6 @@ module.exports = {
"marine_label_point_1": {
"color": "#a9c4c7",
"size": ["stops",
- {"z": 0, "val": 20},
{"z": 3, "val": 20},
{"z": 4, "val": 25},
{"z": 5, "val": 30},
@@ -2219,7 +2258,6 @@ module.exports = {
"marine_label_point_2": {
"color": "#a9c4c7",
"size": ["stops",
- {"z": 0, "val": 13},
{"z": 3, "val": 13},
{"z": 4, "val": 14},
{"z": 5, "val": 20},
@@ -2231,7 +2269,6 @@ module.exports = {
"marine_label_point_other": {
"color": "#a9c4c7",
"size": ["stops",
- {"z": 0, "val": 12},
{"z": 3, "val": 12},
{"z": 4, "val": 13},
{"z": 5, "val": 15},
@@ -2253,9 +2290,6 @@ module.exports = {
{"z": 10, "val": 0}
]
},
- "place_label_city_point": {
- "color": "#4a4032"
- },
"place_label_city": {
"color": "#444",
"strokeWidth": 0.4,
@@ -2267,20 +2301,12 @@ module.exports = {
{"z": 7, "val": 14},
{"z": 14.99, "val": 20},
{"z": 15, "val": 0}
- ],
- "translate": [
- 0,
- [
- "stops",
- {"z": 4, "val": 10},
- {"z": 6, "val": 30},
- {"z": 7, "val": 0}
- ]
]
},
"place_label_town": {
"color": "#716656",
- "strokeWidth": 0.5,
+ "strokeWidth": 0.3,
+ "strokeBlur": 2,
"stroke": "text_stroke",
"size": [
"stops",
@@ -2292,7 +2318,8 @@ module.exports = {
},
"place_label_village": {
"color": "#635644",
- "strokeWidth": 0.5,
+ "strokeWidth": 0.3,
+ "strokeBlur": 2,
"stroke": "text_stroke",
"size": [
"stops",
@@ -2308,18 +2335,32 @@ module.exports = {
"stroke": "text_stroke",
"size": [
"stops",
- {"z": 0, "val": 10},
- {"z": 14, "val": 11},
- {"z": 15, "val": 12},
- {"z": 16, "val": 14}
+ {"z": 13, "val": 11},
+ {"z": 14, "val": 12},
+ {"z": 16, "val": 14},
+ {"z": 18, "val": 18}
]
},
- "road_label": {
+ "road_label_1": {
+ "color": "#585042",
+ "stroke": "land",
+ "strokeWidth": 0.6,
+ "strokeBlur": 2,
+ "size": "road_label_1_size"
+ },
+ "road_label_2": {
+ "color": "#585042",
+ "stroke": "land",
+ "strokeWidth": 0.6,
+ "strokeBlur": 2,
+ "size": "road_label_2_size"
+ },
+ "road_label_3": {
"color": "#585042",
"stroke": "land",
"strokeWidth": 0.6,
"strokeBlur": 2,
- "size": "road_label_size"
+ "size": "road_label_3_size"
},
"water_label": {
"color": "water_dark",
@@ -2400,7 +2441,7 @@ module.exports = {
"color": "land_night"
},
"admin_maritime_cover": {
- "color": "#0a1347",
+ "color": "water_night",
"width": 5
},
"admin_maritime": {
@@ -2555,7 +2596,7 @@ module.exports = {
"prerender-blur": 1,
"opacity": [
"stops",
- {"z": 0, "val": 0.3},
+ {"z": 16, "val": 0.3},
{"z": 17, "val": 0.2},
{"z": 18, "val": 0.1}
]
@@ -2568,7 +2609,7 @@ module.exports = {
"prerender-blur": 1,
"opacity": [
"stops",
- {"z": 0, "val": 0.3},
+ {"z": 16, "val": 0.3},
{"z": 17, "val": 0.2},
{"z": 18, "val": 0.1}
]
@@ -2940,7 +2981,8 @@ module.exports = {
},
"country_label": {
"color": "text_night",
- "stroke": "text_stroke_night",
+ "stroke": "text2_stroke_night",
+ "strokeWidth": 0.4,
"size": "country_label_size"
},
"country_label_line": {
@@ -2955,7 +2997,6 @@ module.exports = {
"marine_label_point_1": {
"color": "water_dark_night",
"size": ["stops",
- {"z": 0, "val": 20},
{"z": 3, "val": 20},
{"z": 4, "val": 25},
{"z": 5, "val": 30},
@@ -2966,7 +3007,6 @@ module.exports = {
"marine_label_point_2": {
"color": "water_dark_night",
"size": ["stops",
- {"z": 0, "val": 13},
{"z": 3, "val": 13},
{"z": 4, "val": 14},
{"z": 5, "val": 20},
@@ -2978,7 +3018,6 @@ module.exports = {
"marine_label_point_other": {
"color": "#a9c4c7",
"size": ["stops",
- {"z": 0, "val": 12},
{"z": 3, "val": 12},
{"z": 4, "val": 13},
{"z": 5, "val": 15},
@@ -3000,13 +3039,10 @@ module.exports = {
{"z": 10, "val": 0}
]
},
- "place_label_city_point": {
- "color": "#ddd"
- },
"place_label_city": {
"color": "#fff",
"strokeWidth": 0.4,
- "stroke": "text_stroke_night",
+ "stroke": "text2_stroke_night",
"size": [
"stops",
{"z": 3.99, "val": 0},
@@ -3014,21 +3050,13 @@ module.exports = {
{"z": 7, "val": 14},
{"z": 14.99, "val": 20},
{"z": 15, "val": 0}
- ],
- "translate": [
- 0,
- [
- "stops",
- {"z": 4, "val": 10},
- {"z": 6, "val": 30},
- {"z": 7, "val": 0}
- ]
]
},
"place_label_town": {
"color": "text_night",
- "strokeWidth": 0.5,
- "stroke": "text_stroke_night",
+ "strokeWidth": 0.3,
+ "strokeBlur": 2,
+ "stroke": "text2_stroke_night",
"size": [
"stops",
{"z": 9, "val": 10},
@@ -3039,8 +3067,9 @@ module.exports = {
},
"place_label_village": {
"color": "text_night",
- "strokeWidth": 0.5,
- "stroke": "text_stroke_night",
+ "strokeWidth": 0.3,
+ "strokeBlur": 2,
+ "stroke": "text2_stroke_night",
"size": [
"stops",
{"z": 9, "val": 8},
@@ -3052,32 +3081,47 @@ module.exports = {
},
"place_label_other": {
"color": "text_night",
- "stroke": "text_stroke_night",
- "strokeWidth": 0.5,
- "strokeBlur": 3,
+ "stroke": "text2_stroke_night",
+ "strokeWidth": 0.3,
+ "strokeBlur": 2,
"size": [
"stops",
- {"z": 0, "val": 10},
- {"z": 14, "val": 11},
- {"z": 15, "val": 12},
- {"z": 16, "val": 14}
+ {"z": 13, "val": 11},
+ {"z": 14, "val": 12},
+ {"z": 16, "val": 14},
+ {"z": 18, "val": 18}
]
},
- "road_label": {
+ "road_label_1": {
+ "color": "text_night",
+ "stroke": "text2_stroke_night",
+ "strokeWidth": 0.5,
+ "strokeBlur": 3,
+ "size": "road_label_1_size"
+ },
+ "road_label_2": {
+ "color": "text_night",
+ "stroke": "text2_stroke_night",
+ "strokeWidth": 0.5,
+ "strokeBlur": 3,
+ "size": "road_label_2_size"
+ },
+ "road_label_3": {
"color": "text_night",
"stroke": "text2_stroke_night",
"strokeWidth": 0.5,
"strokeBlur": 3,
- "size": "road_label_size"
+ "size": "road_label_3_size"
},
"water_label": {
"color": "water_dark_night",
- "stroke": "text_stroke_night"
+ "strokeWidth": 0.8,
+ "stroke": "text2_stroke_night"
},
"waterway_label": {
- "color": "land_night",
+ "color": "water_dark_night",
"strokeWidth": 0.8,
- "stroke": "water_night"
+ "stroke": "text2_stroke_night"
},
"poi": {
"color": "white",