Kosmos General Purpose Rules

This page describes a historic artifact in the history of OpenStreetMap. It does not reflect the current situation, but instead documents the historical concepts, issues, or ideas.
About
This page contains the standard set of rendering rules for Kosmos 2.x
Impact on OpenStreetMap
Kosmos was a popular rendering software, these information was the foundation of many other map styles.
Reason for being historic
Kosmos was superseded by Maperitive. It is no longer possible to download Kosmos. Nobody is actively using these rendering rules. The idea of hosting rendering rules on the wiki, and the format used, may be of vague historical interest.
Captured time
2011-05-11

This page contains a set of Kosmos rendering rules for a general purpose map. These rules do not cover the whole range of OSM tagging currently in use, so you are free to edit these rules and add new ones if you feel something is missing. However a couple of things should be noted:

  1. See Kosmos Rendering Help for help on how to write rendering rules.
  2. Before committing changes to the page, please make sure the rules are actually working. Try them with the latest version of Kosmos (2.00 or above), since they are not compatible with previous versions.
  3. These rules are intended for a general-purpose map, so if you want to create specialized maps, the preferred way is to create a new rules page (see Category:Kosmos_rules).

URL of the rules to use in Kosmos: http://wiki.openstreetmap.org/wiki/Kosmos_General_Purpose_Rules

Options

Option Value Comment
MinKosmosVersion2.1Minimal version of Kosmos needed to use these rules
LandBackgroundColor#F8F8F8
SeaColor#B5D6F1

Land Areas

Rule Name Targets Selector Template Options Comment
Coastlinenatural=coastlinePolyline (MinZoom=1, Color=#8BCCE5, Width=11:1;17:5, Curved=true)
Beachnatural=beachPolygon (Color=#ffbc09)
Woodnatural=woodPolygon (Color=#99DB9C)
Scrubnatural=scrubPolygon (Color=#99EE9C)
Fellnatural=fellPolygon (Color=#CDDB69)
Farmlanduse=farmPolygon (Color=#EBE0AF)
Farmlanduse=farmlandPolygon (Color=#B7EBAF)
Quarrylanduse=quarryPolygon (Color=#FEADB8)
Residentiallanduse=residentialPolygon (Color=#DCDCDC)
Industriallanduse=industrialPolygon (Color=#FEADB8)
Commerciallanduse=commercialPolygon (Color=#EFC8C8)
Retaillanduse=retailPolygon (Color=#F0DADA)
Reservoirlanduse=reservoirPolygon (Color=#B5D0D0)
Basinlanduse=basinPolygon (Color=#B5D0D0)
Forestlanduse=forestPolygon (Color=#CFECA8)
Cemeterylanduse=cemeteryPolygon (Color=#A9CAAE, BackgroundColor=#75AC7D, HatchStyle=DashedVertical)
Allotmentslanduse=allotmentsPolygon (Color=#C8B084)
Grasslanduse=grassPolygon (Color=#28d25c)
Skiingsport=skiingPolygon (Color=#CDDB69)
HorseRacingsport=horse_racingPolygon (Color=peru)
Tennissport=tennisPolygon (Color=lightsalmon)
Swimmingsport=swimmingPolygon (Color=lightblue)
Parkleisure=parkPolygon (Color=#C7F1A3)
Pitchleisure=pitchPolygon (Color=#8AD2AE)
GolfCourseleisure=golf_coursePolygon (Color=#7CCC7C)
Commonleisure=commonPolygon (Color=#CFECA8)

Water Features

Rule Name Targets Selector Template Options Comment
Waternatural=waterPolygon (Color=lightblue)
Marshnatural=marshPolygon (Color=blue, BackgroundColor=#00000000, BorderColor=blue, BorderWidth=1:1;12:1;15:3, HatchStyle=DashedHorizontal)
Riverwaterway=riverPolyline (MinZoom=5, Color=lightblue, Width=5:1;10:2;17:14, Curved=true)
Drainwaterway=drainPolyline (MinZoom=13, Color=lightblue, Width=13:1;17:6, Curved=true)
Streamwaterway=streamPolyline (MinZoom=13, Color=lightblue, Width=13:1;17:6, Curved=true)
Canalwaterway=canalPolyline (MinZoom=5, Color=lightblue, Width=5:1;10:1;17:10, Curved=true)
Riverbankwaterway=riverbankPolygon (Color=lightblue)
Landnatural=landPolygon (Color=white)

Other Land Features

Rule Name Targets Selector Template Options Comment
Contoursele=*for elevation contours generated by Srtm2Osm
.MajorValueNum(e,"ele") % 100 = 0Polyline (MinZoom=11, Color=#B0AD8852, Width=11:1;12:2, Curved=true)Major contours (100m ones)
.*Polyline (MinZoom=12, Color=#B0AD8852, Width=1, Curved=true)all other contours


Highways

Rule Name Targets Selector Template Options Comment
HighwayFootwayhighway=footwayPolyline (MinZoom=13, Color=#FFDE93, BorderColor=gray, Width=13:1;17:6)EliminateSeams
HighwayFootwayTexthighway=footwayText (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9)
HighwayPathhighway=pathPolyline (MinZoom=13, Color=#FFDE93, DashStyle=Dash, BorderColor=gray, Width=13:1;17:6)EliminateSeams
HighwayPathTexthighway=pathText (MinZoom=15, Color=black, DashStyle=Dash,TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9)
HighwayStepshighway=stepsPolyline (MinZoom=13, Color=#FFDE93, DashStyle=Dot, BorderColor=gray, Width=13:1;17:6)EliminateSeams
HighwayBridlewayhighway=bridlewayPolyline (MinZoom=13, Color=#DDDDDD, BorderColor=gray, Width=13:1;17:6)EliminateSeams
HighwayBridlewayTexthighway=bridlewayText (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9)
HighwayCiclewayhighway=cyclewayPolyline (MinZoom=13, Color=#0202FE, DashStyle=Dash, Width=13:1;17:4)EliminateSeams
HighwayUnpavedhighway=unpavedPolyline (MinZoom=11, Color=#E2E2E2, BorderColor=gray, Width=11:1;14:3;17:10)EliminateSeams
HighwayUnpavedTexthighway=unpavedText (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9)
HighwayUnsurfacedhighway=unsurfacedPolyline (MinZoom=11, Color=#E2E2E2, BorderColor=gray, Width=11:1;14:3;17:10)EliminateSeamsdeprecated
HighwayUnclassifiedhighway=unclassifiedPolyline (MinZoom=11, Color=white, BorderColor=gray, Width=11:1;13:3;17:14)EliminateSeams
HighwayUnclassifiedTexthighway=unclassifiedText (MinZoom=16, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9)
HighwayPedestrianhighway=pedestrianPolyline (MinZoom=13, Color=lightgray, BorderColor=gray, Width=14:3;17:14)EliminateSeams
HighwayPedestrianAreahighway=pedestrian area=yesPolygon (MinZoom=13, Color=lightgray, BorderColor=gray, BorderWidth=1)
Text (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9, TextMode=AreaCenter)
EliminateSeams
HighwayUnclassifiedAreahighway=unclassified area=yesPolygon (MinZoom=13, Color=white, BorderColor=gray, BorderWidth=1)
Text (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9, TextMode=AreaCenter)
EliminateSeams
HighwayResidentialAreahighway=residential area=yesPolygon (MinZoom=13, Color=white, BorderColor=gray, BorderWidth=1)
Text (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9, TextMode=AreaCenter)
EliminateSeams
HighwayPedestrianTexthighway=pedestrianText (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9)
HighwayResidentialhighway=residentialPolyline (MinZoom=11, Color=white, BorderColor=gray, Width=11:1;13:3;17:14)EliminateSeams
HighwayResidentialTexthighway=residentialText (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9)
HighwayPedestrianPriorityhighway=living_streetPolyline (MinZoom=11, Color=white, BorderColor=gray, Width=11:1;13:3;17:14)EliminateSeams
HighwayPedestrianPriorityTexthighway=living_streetText (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9)
HighwayServicehighway=servicePolyline (MinZoom=12, Color=white, BorderColor=gray, Width=12:1;13:2;17:6)EliminateSeams
HighwayServiceTexthighway=serviceText (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:5;17:9)
HighwayMinorhighway=minorPolyline (MinZoom=12, Color=white, BorderColor=gray, Width=12:1;13:2;17:13)EliminateSeams
HighwayMinorTexthighway=minorText (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:5;17:8)
HighwayTrackhighway=trackPolyline (MinZoom=11, Color=#E2E2E2, BorderColor=gray, Width=11:1;14:3;17:10)EliminateSeams
HighwayTertiaryhighway=tertiaryPolyline (MinZoom=10, Color=#F7F496, BorderColor=gray, Width=10:1;13:4;17:14)EliminateSeams
HighwayTertiaryTexthighway=tertiaryText (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9)
HighwaySecondaryhighway=secondaryEliminateSeams
.Bridgebridge=yesPolyline (MinZoom=8, Color=#FDBF6F, BorderColor=gray, Width=8:1;10:2;13:6;17:14, BorderWidth=30%)
.*Polyline (MinZoom=8, Color=#FDBF6F, BorderColor=gray, Width=8:1;10:2;13:6;17:14)
HighwaySecondaryTexthighway=secondaryText (MinZoom=15, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=15:6;17:9)
HighwayPrimaryhighway=primaryEliminateSeams
.Bridgebridge=yesPolyline (MinZoom=6, Color=#E46D71, BorderColor=gray, Width=6:0;11:3;17:14, BorderWidth=30%)
.*Polyline (MinZoom=6, Color=#E46D71, BorderColor=gray, Width=6:0;11:3;17:14)
HighwayPrimaryTexthighway=primaryText (MinZoom=13, Color=#E46D71, BorderColor=#E46D71, BorderWidth=2, BackgroundColor=white, TagToUse=ref, TextMode=WayCenter, FontName=Arial, FontStyle=bold, FontSize=13:8;17:12)
HighwayPrimaryLinkhighway=primary_linkPolyline (MinZoom=6, Color=#E46D71, BorderColor=gray, Width=6:1;17:14)EliminateSeams
HighwayTrunkhighway=trunkPolyline (MinZoom=6, Color=#41A317, BorderColor=gray, Width=6:1;17:14)EliminateSeams
HighwayTrunkLinkhighway=trunk_linkPolyline (MinZoom=6, Color=#41A317, BorderColor=gray, Width=6:1;17:14)EliminateSeams
HighwayMotorwayhighway=motorwayEliminateSeams
.Bridgebridge=yesPolyline (MinZoom=6, Color=#809BC0, BorderColor=gray, Width=6:1;17:14, BorderWidth=30%)
.*Polyline (MinZoom=6, Color=#809BC0, BorderColor=gray, Width=6:1;17:14)
HighwayMotorwayLinkhighway=motorway_linkPolyline (MinZoom=6, Color=#809BC0, BorderColor=gray, Width=6:1;17:8)EliminateSeams

Transport

Rule Name Targets Selector Template Options Comment
Railrailway=railPolyline (MinZoom=6, Color=white, DashStyle=Dot, BorderColor=gray, Width=6:1;17:6)EliminateSeams
.tunneltunnel=yesPolyline (MinZoom=6, Color=white, DashStyle=solid, BorderColor=gray, BorderDashStyle=Dash, Width=6:1;17:6)EliminateSeams
Light-Railrailway=light_railPolyline (MinZoom=6, Color=black, DashStyle=solid, BorderColor=gray, Width=6:1;17:2)EliminateSeams
.tunneltunnel=yesPolyline (MinZoom=6, Color=white, DashStyle=solid, BorderColor=black, BorderDashStyle=Dash, Width=6:1;17:2)EliminateSeams
Tramrailway=tramPolyline (MinZoom=6, Color=black, DashStyle=solid, BorderColor=gray, Width=6:1;17:2)EliminateSeams
.tunneltunnel=yesPolyline (MinZoom=6, Color=white, DashStyle=solid, BorderColor=black, BorderDashStyle=Dash, Width=6:1;17:2)EliminateSeams
Subwayrailway=subwayPolyline (MinZoom=6, Color=black, DashStyle=Dash, BorderColor=gray, Width=6:1;17:2)EliminateSeams
.tunneltunnel=yesPolyline (MinZoom=6, Color=white, DashStyle=Dash, BorderColor=gray, BorderDashStyle=Dash, Width=6:1;17:2)EliminateSeams
RailDisusedrailway=disusedPolyline (MinZoom=10, Color=white, DashStyle=Dot, BorderColor=#DDDDDD, Width=10:1;17:4)EliminateSeams
CableCaraerialway=cable_carSymbol (MinZoom=12, Type=Circle, Density=30, Color=#00000000, BorderWidth=20%, BorderColor=black, Size=12:2;17:10)
Polyline (MinZoom=12, Color=black, Width=12:0.5;17:3)
DragLiftaerialway=drag_liftSymbol (MinZoom=12, Type=Circle, Density=30, Color=#00000000, BorderWidth=10%, BorderColor=black, Size=12:2;17:10)
Polyline (MinZoom=12, Color=black, Width=12:0.5;17:2)
ChairLiftaerialway=chair_liftSymbol (MinZoom=12, Type=Circle, Density=30, Color=#00000000, BorderWidth=10%, BorderColor=black, BackgroundColor=black, Size=12:2;17:10)
Polyline (MinZoom=12, Color=black, Width=12:0.5;17:2)
Ferryroute=ferryPolyline (MinZoom=8, Color=darkgray, DashStyle=Dot, Width=8:0.1;17:4)

Other Ways

Rule Name Targets Selector Template Options Comment
BoundaryAdministrativeboundary=administrative
.level2admin_level=2Polyline (MinZoom=1, Color=red, DashStyle=DashDot, Width=1:1;9:1.5;17:6)
.level4admin_level=4Polyline (MinZoom=10, Color=black, DashStyle=DashDot, Width=1:1;9:1.5;17:6)
.level8admin_level=8Polyline (MinZoom=12, Color=#A4A4A4, DashStyle=Dot, Width=1:1;9:1.5;5:5))
.*Polyline (MinZoom=12, Color=black, DashStyle=DashDot, Width=1:1;9:1.5;17:6)
BoundaryNationalParkboundary=national_parkPolyline (MinZoom=9, Color=green, DashStyle=DashDot, Width=9:1.5;17:6)
Runwayaeroway=runwayPolyline (MinZoom=11, Color=#BBBBCC, Width=11:1;17:30)
Taxiwayaeroway=taxiwayPolyline (MinZoom=12, Color=#BBBBCC, Width=12:1;17:10)

Places

Rule Name Targets Selector Template Options Comment
PlaceCountryplace=countryText (MinZoom=3, MaxZoom=7, Color=black, TagToUse=name, FontName=Trebuchet MS, FontStyle=bold, FontSize=3:7;7:20, OutlineColor=white)
PlaceCityplace=cityText (MinZoom=7, MaxZoom=14, Color=black, TagToUse=name, FontName=Trebuchet MS, FontStyle=bold, FontSize=7:10;17:30, OutlineColor=white, OutlineWidth=20%)
PlaceTownplace=townText (MinZoom=10, MaxZoom=15, Color=black, TagToUse=name, FontName=Trebuchet MS, FontStyle=bold, FontSize=10:10;17:25, OutlineColor=white)
PlaceVillageplace=villageText (MinZoom=12, MaxZoom=16, Color=black, TagToUse=name, FontName=Trebuchet MS, FontStyle=bold, FontSize=12:10;17:20, OutlineColor=white)
PlaceIslandplace=islandText (MinZoom=12, MaxZoom=16, Color=black, TagToUse=name, FontName=Trebuchet MS, FontStyle=bold, FontSize=12:10;17:20, OutlineColor=white)
PlaceSuburbplace=suburbText (MinZoom=13, MaxZoom=16, Color=black, TagToUse=name, FontName=Trebuchet MS, FontStyle=bold, FontSize=13:10;17:20, OutlineColor=white)
PlaceHamletplace=hamletText (MinZoom=14, MaxZoom=17, Color=black, TagToUse=name, FontName=Trebuchet MS, FontStyle=bold, FontSize=14:8;17:14, OutlineColor=white)
PlaceLocalityplace=localityText (MinZoom=14, MaxZoom=17, Color=black, TagToUse=name, FontName=Trebuchet MS, FontStyle=bold, FontSize=14:8;17:14, OutlineColor=white)
PlaceFarmplace=farmText (MinZoom=15, MaxZoom=19, Color=black, TagToUse=name, FontName=Trebuchet MS, FontStyle=bold, FontSize=15:8;17:13, OutlineColor=white)

Buildings

Rule Name Targets Selector Template Options Comment
BuildingResidentialbuilding=residentialPolygon (MinZoom=12, Color=#F3D6B6, BorderColor=#6B5B8E, BorderWidth=1)
BuildingAnybuilding=*Polygon (MinZoom=13, Color=thistle, BorderColor=#6B5B8E, BorderWidth=1)
Text (MinZoom=16, Color=black, TagToUse=name, FontName=Arial, FontStyle=regular, FontSize=16:6;17:10, TextMode=AreaCenter)
Rule Name Targets Selector Template Options Comment
NavaidBuoyman_made=buoySymbol (Type=Diamond, MinZoom=11, Color=blue, BorderColor=black, BorderWidth=15%, Size=13:6;17:20)
NavaidLighthouseman_made=lighthouseSymbol (Type=Triangle, MinZoom=10, Color=blue, BorderColor=black, BorderWidth=15%, Size=13:6;17:20)

Routes

Rule Name Targets Selector Template Options Comment
National Network Cycle Routesnetwork=ncnPolyline (MinZoom=7, Color=#60FF0718, Width=1:2;17:10, Curved=true)
Local Network Cycling Routesnetwork=lcnPolyline (MinZoom=7, Color=#803E2BF0, Width=1:1;17:5, Curved=true)
This article is issued from Openstreetmap. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.