Skip to content

Latest commit

 

History

History
103 lines (73 loc) · 2.37 KB

Maps-Mapbox.md

File metadata and controls

103 lines (73 loc) · 2.37 KB

Tilemill

install Tilemill on Mac (developer edition): http://tilemill.s3.amazonaws.com/dev/TileMill-v0.10.1-312-gfaf6910.zip

open Tilemill (when built from source):
cd Tilemill
node index.js


CartoCSS - most basic styles

duplicates the layer, in this case to insert an outline and inline:

#layer {
  ::outline {
    line-width: 6;
    line-color: black;
  }
  line-width: 2;
  line-color: white;
}

styles every sub-type differently:

#roads {
  [class='motorway'] {line-width: 4;}
  [class='main'] {line-width: 2;}
  [class='street'] {line-width: 1;}
}

styles everything in a spcific zoom level:

#layer[zoom>=4][zoom<=10] {line-width: 1;}
#cities {
  [zoom>=4][population>1000000],
  [zoom>=5][population>500000],
  [zoom>=6][population>100000] {text-name: [name];}
}

selects everything that is NOT a certain type:

#roads[class!='motorway'] {line-width: 1;}

Useful links:


File formats

Extension Explanation
OSM Open Street Map
Geo-JSON -
.shp Shapefile. Common standard for representing geospatial vector data (describes points, polygons and lines)
.pbf -
.pbf -
GTFS -
GML -
GPX an XML schema designed as a common GPS data format
WFS -
GIS Geographic Information System. Used when talking about "GIS Software" (http://en.wikipedia.org/wiki/List_of_geographic_information_systems_software) like ArgGIS or QGis