mirror of
https://github.com/enzet/map-machine.git
synced 2025-06-09 14:21:50 +02:00
Issue #91: support automatic icon generation.
Use regular expressions to match tags and construct icons using matched substrings.
This commit is contained in:
parent
4644d38166
commit
39acfc6ff6
4 changed files with 102 additions and 88 deletions
|
@ -1267,29 +1267,11 @@ node_icons:
|
|||
shapes: [buffer_stop]
|
||||
- tags: {traffic_sign: city_limit}
|
||||
shapes: [city_limit_sign]
|
||||
- tags: {traffic_sign: maxspeed, maxspeed: "30"}
|
||||
- tags: {traffic_sign: maxspeed, maxspeed: "(\\d)(\\d)"}
|
||||
shapes: [
|
||||
circle_11,
|
||||
{shape: digit_3, offset: [-2, 0], color: "#FFFFFF"},
|
||||
{shape: digit_0, offset: [2, 0], color: "#FFFFFF"},
|
||||
]
|
||||
- tags: {traffic_sign: maxspeed, maxspeed: "40"}
|
||||
shapes: [
|
||||
circle_11,
|
||||
{shape: digit_4, offset: [-2, 0], color: "#FFFFFF"},
|
||||
{shape: digit_0, offset: [2, 0], color: "#FFFFFF"},
|
||||
]
|
||||
- tags: {traffic_sign: maxspeed, maxspeed: "50"}
|
||||
shapes: [
|
||||
circle_11,
|
||||
{shape: digit_5, offset: [-2, 0], color: "#FFFFFF"},
|
||||
{shape: digit_0, offset: [2, 0], color: "#FFFFFF"},
|
||||
]
|
||||
- tags: {traffic_sign: maxspeed, maxspeed: "60"}
|
||||
shapes: [
|
||||
circle_11,
|
||||
{shape: digit_6, offset: [-2, 0], color: "#FFFFFF"},
|
||||
{shape: digit_0, offset: [2, 0], color: "#FFFFFF"},
|
||||
{shape: digit_#maxspeed0, offset: [-2, 0], color: "#FFFFFF"},
|
||||
{shape: digit_#maxspeed1, offset: [2, 0], color: "#FFFFFF"},
|
||||
]
|
||||
- tags: {traffic_sign: maxspeed, maxspeed: "40_mph"}
|
||||
shapes: [
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue