ADD 6 types of boundaries to map_features.xml
authorSteve Bennett <stevagewp@gmail.com>
Sun, 9 Jan 2011 01:02:32 +0000 (01:02 +0000)
committerSteve Bennett <stevagewp@gmail.com>
Sun, 9 Jan 2011 01:02:32 +0000 (01:02 +0000)
ADD several boundary types to potlatch.css, including a catch-all
REMOVE way[sport] from potlatch.css (it is only a support tag, should theoretically not be rendered without an accompanying leisure=, amenity= etc.
TODO icons for boundaries in map_features.xml
TODO work out whether the other boundary types are worth supporting (and wtf the difference between boundary=town and place=town is)

resources/map_features.xml
resources/potlatch.css

index d9170e6..4d46252 100644 (file)
@@ -3507,17 +3507,71 @@ Quick documentation:
     <inputSet ref="common"/>
   </feature>
 
-  <!-- boundaries -->
+  <!-- Top 10 boundaries in order of usage on taginfo.openstreetmap.de -->
 
-  <feature name="Administrative Boundary">
+  <feature name="Admin Boundary">
     <category>places</category>
     <line/>
     <icon image="features/pois/poi_boundary_administrative.n.24.png"/>
     <help>http://wiki.openstreetmap.org/wiki/Tag:boundary=administrative</help>
     <tag k="boundary" v="administrative"/>
     <input type="number" minimum="2" maximum="10" presence="always" name="Admin Level" key="admin_level" description="The Administrative level" />
+    <inputSet ref="simpleName"/>
+    <inputSet ref="common"/>
+  </feature>
+
+  <feature name="National Park">
+    <category>places</category>
+    <category>natural</category>
+    <line/>
+    <help>http://wiki.openstreetmap.org/wiki/Tag:boundary=national_park</help>
+    <tag k="boundary" v="national_park"/>
+    <inputSet ref="simpleName"/>
+    <inputSet ref="common"/>
   </feature>
 
+  <feature name="Post Code">
+    <category>places</category>
+    <line/>
+    <help>http://wiki.openstreetmap.org/wiki/Tag:boundary=postal_code</help>
+    <tag k="boundary" v="postal_code"/>
+    <inputSet ref="simpleName"/>
+    <inputSet ref="common"/>
+  </feature>
+
+  <feature name="Protected Area">
+    <category>places</category>
+    <category>natural</category>
+    <line/>
+    <help>http://wiki.openstreetmap.org/wiki/Tag:boundary=protected_area</help>
+    <tag k="boundary" v="protected_area"/>
+    <inputSet ref="simpleName"/>
+    <inputSet ref="common"/>
+  </feature>
+
+  <feature name="Town boundary">
+    <category>places</category>
+    <line/>
+    <help>http://wiki.openstreetmap.org/wiki/Tag:boundary=town</help>
+    <tag k="boundary" v="town"/>
+    <inputSet ref="simpleName"/>
+    <inputSet ref="common"/>
+  </feature>
+
+  <!-- boundary=landuse goes here. no idea what it is.-->
+
+  <feature name="Census boundary">
+    <category>places</category>
+    <line/>
+    <help>http://wiki.openstreetmap.org/wiki/Tag:boundary=census</help>
+    <tag k="boundary" v="census"/>
+    <inputSet ref="simpleName"/>
+    <inputSet ref="common"/>
+  </feature>
+
+  <!-- next three are marker, postcode_area, administrative. all seem dubious -->
+  
+
   <!-- ************************************************************************
        Relations
        ************************************************************************ -->
index 7c3c51f..fe75b8d 100644 (file)
@@ -92,7 +92,8 @@ way[landuse=retail] :area                   { color: #cc2222; width: 2; fill-col
 way[landuse=commercial] :area               { color: #4444bb; width: 2; fill-color: #444488; fill-opacity: 0.15; }
 way[landuse=military] :area                 { color: #ff4444; width: 2; fill-color: #ff4444; fill-opacity: 0.2; set .area_small_name; }
 way[amenity],way[shop] :area                { color: #ADCEB5; width: 1; fill-color: #ADCEB5; fill-opacity: 0.2; }
-way[leisure],way[sport] :area               { color: #8CD6B5; width: 1; fill-color: #8CD6B5; fill-opacity: 0.2; }
+/* way[sport] should not be rendered by itself, according to wiki. Can we make it an "if all else fails"? */
+way[leisure] :area                         { color: #8CD6B5; width: 1; fill-color: #8CD6B5; fill-opacity: 0.2; }
 way[tourism] :area                          { color: #F7CECE; width: 1; fill-color: #F7CECE; fill-opacity: 0.2; set .area_small_name;}
 way[historic],way[ruins] :area              { color: #F7F7DE; width: 1; fill-color: #F7F7DE; fill-opacity: 0.2; set .area_small_name;}
 way[military] :area                         { color: #D6D6D6; width: 1; fill-color: #D6D6D6; fill-opacity: 0.2; set .area_small_name;}
@@ -117,6 +118,10 @@ way[leisure=marina] :area                                  { color: pink; fill-color: pink; fill-opacity: 0.4
 way[leisure=slipway]                                           { color: grey; width: 3; casing-color: blue; casing-width: 7; }
 way[leisure=golf_course] :area { color: #44ee22; width: 2; fill-color: #44ee22; fill-opacity: 0.2; set .area_small_name;}
 
+way[boundary]                               { color: #000066; width: 2; opacity: 0.6; dashes: 24,4, 4, 4; z-index: 4;}
+/* Perhaps should be filled, on lower zooms. */
+way[boundary=national_park]                 { color: #225500; width: 2; opacity: 0.6; dashes: 24,4, 4, 4; z-index: 4;}
+way[boundary=protected_area]                { color: #447744; width: 2; opacity: 0.6; dashes: 12,4, 4, 4; z-index: 4;}
 way[boundary=administrative]                { color: purple; width: 2; opacity: 0.2; dashes: 24,4; z-index: 4;}
 way[boundary=administrative][waterway]      { opacity: 0.8; z-index: 4; dashes: 24,4; width: 6; }
 way[landuse=cemetery]                                          { color: #664466; width: 2; fill-color: color: #664466; opacity: 0.2; set .area_small_name;}