| | 1 | == Mountain terrain style == |
| | 2 | |
| | 3 | This style |
| | 4 | * paints ways natural=ridge, natural=arete |
| | 5 | * add icons for nodes natural=peak, natural=volcano, mountain_pass=yes, ele=* |
| | 6 | * draw legible labels for elements above |
| | 7 | |
| | 8 | [[Image(kent.png)]] |
| | 9 | |
| | 10 | === The style itself === |
| | 11 | {{{ |
| | 12 | #!style type="mapcss" |
| | 13 | |
| | 14 | meta { |
| | 15 | title: "Mountains"; |
| | 16 | description: "Indication mountain terrain tags"; |
| | 17 | author: "lzhl"; |
| | 18 | version: "0.[[revision]]_[[date]]"; |
| | 19 | watch-modified: true; |
| | 20 | } |
| | 21 | |
| | 22 | /* hide nodes */ |
| | 23 | node|z1-13 {symbol-shape: square; symbol-fill-opacity: 0; symbol-size: 1; z-index: -1;} |
| | 24 | node|z14-15 {symbol-shape: square; symbol-stroke-color: #FFFF00; symbol-size: 4; z-index: 1;} |
| | 25 | node|z16- {symbol-shape: square; symbol-stroke-color: #FFFF00; symbol-size: 5; z-index: 1;} |
| | 26 | |
| | 27 | /* not fill national parks */ |
| | 28 | area[boundary=national_park], relation[boundary=national_park], way[leisure=nature_reserve], relation[leisure=nature_reserve] > way {opacity: 0.5; color: #CDCDC1; width: 1; fill-opacity: 0;} |
| | 29 | |
| | 30 | /* lines color and width */ |
| | 31 | way[natural=ridge] {color: #773900; width: 4;} |
| | 32 | way[natural=cliff] {color: #004400; width: 3;} |
| | 33 | way[natural=arete] {color: #441144; width: 3;} |
| | 34 | way[natural=ridge][cliff=yes] {color: #775500; width: 4;} |
| | 35 | way[natural=ridge][arete=yes] {color: #773939; width: 4;} |
| | 36 | way[natural=glacier], relation[natural=glacier] {color: #9f9fff; fill-color: #ddddff; width: 2;} |
| | 37 | |
| | 38 | /* icons */ |
| | 39 | node[natural=peak] {icon-image: http://mountainclub.ru/osm/icons/peak_small.png;} |
| | 40 | node[natural=volcano] {icon-image: http://mountainclub.ru/osm/icons/volcano_small.png;} |
| | 41 | node[mountain_pass=yes] {icon-image: http://mountainclub.ru/osm/icons/pass.png;} |
| | 42 | |
| | 43 | node|z1-12[ele] {symbol-shape: circle; symbol-stroke-color: #000000; symbol-size: 5; z-index: 1;} |
| | 44 | node|z13-[ele] {symbol-shape: circle; symbol-stroke-color: #000000; symbol-size: 7; z-index: 1;} |
| | 45 | |
| | 46 | /* labels */ |
| | 47 | node|z1-11[natural=peak], node|z1-11[mountain_pass=yes] {text-opacity: 0} |
| | 48 | node|z12[natural=peak], node|z12[mountain_pass=yes] {font-size: 10; text-color: #000000; text-halo-color: #ffffff; text-halo-radius: 1.8; text: ele;} |
| | 49 | node|z12[natural=peak][name], node|z12[mountain_pass=yes][name] {font-size: 10; text-color: #000000; text-halo-color: #ffffff; text: name} |
| | 50 | node|z13-[natural=peak], node|z13-[mountain_pass=yes] {font-size: 12; font-weight: bold; text-color: #000000; text-halo-color: #ffffff; text-halo-radius: 2; text: ele;} |
| | 51 | node|z13-[natural=peak][name], node|z13-[mountain_pass=yes][name] {font-size: 12; font-weight: bold; text-color: #000000; text-halo-color: #ffffff; text: name;} |
| | 52 | |
| | 53 | node|z13-[!natural][!mountain_pass][ele] {font-size: 12; font-weight: bold; text-color: #000000; text-halo-color: #ffffff; text-halo-radius: 2; text: ele;} |
| | 54 | |
| | 55 | way|z1-11[natural=ridge] {font-size: 11; font-weight: bold; text-color: #773900; text-halo-color: #ffffff; text-halo-radius: 2; text: name;} |
| | 56 | way|z12-[natural=ridge] {font-size: 11; font-weight: bold; text-color: #773900; text-halo-color: #ffffff; text-halo-radius: 1.8; text: name;} |
| | 57 | }}} |