1 | /*
|
---|
2 | OpenRailwayMap Style File for JOSM
|
---|
3 | OpenRailwayMap - Copyright (C) 2023 user: mikeho
|
---|
4 | This program comes with ABSOLUTELY NO WARRANTY.
|
---|
5 | This is free software, and you are welcome to redistribute it under certain conditions.
|
---|
6 | See https://wiki.openstreetmap.org/wiki/OpenRailwayMap for details.
|
---|
7 |
|
---|
8 | Format details: https://josm.openstreetmap.de/wiki/Help/Styles/MapCSSImplementation
|
---|
9 | https://wiki.openstreetmap.org/wiki/MapCSS/0.2
|
---|
10 | */
|
---|
11 |
|
---|
12 | meta {
|
---|
13 | title: "JOSM - Maxspeed as Text - 19.02.2023 - Version 1.0";
|
---|
14 | version: "1.0";
|
---|
15 | description: "Style to display the maxspeed as Text on a OSM-Way.";
|
---|
16 | author: "mikeho";
|
---|
17 | watch-modified: true;
|
---|
18 | }
|
---|
19 |
|
---|
20 | canvas {
|
---|
21 | default-points: true;
|
---|
22 | default-lines: true;
|
---|
23 | }
|
---|
24 |
|
---|
25 | way|z17-["railway"="rail"] { set is_rail; }
|
---|
26 |
|
---|
27 | way[ is_prop_set("is_rail", "default") ]::layer_speed_for {
|
---|
28 | text-offset-y: 6;
|
---|
29 | font-size: 18;
|
---|
30 |
|
---|
31 | text: concat("Vmax",
|
---|
32 | has_tag_key("maxspeed") ? concat(": " , tag("maxspeed") , " ") : "",
|
---|
33 | has_tag_key("maxspeed:forward") ? concat("-forw: ", tag("maxspeed:forward" ), " ") : "",
|
---|
34 | has_tag_key("maxspeed:backward") ? concat("-back: ", tag("maxspeed:backward")) : ""
|
---|
35 | );
|
---|
36 |
|
---|
37 | text-position: line;
|
---|
38 | text-color: #F44; text-halo-opacity: 1;
|
---|
39 | text-halo-color: #202020; text-halo-radius: 4;
|
---|
40 | text-allow-overlap: true;
|
---|
41 | }
|
---|