diff --git a/vtm-android-example/AndroidManifest.xml b/vtm-android-example/AndroidManifest.xml index dd3898de..e5404b01 100644 --- a/vtm-android-example/AndroidManifest.xml +++ b/vtm-android-example/AndroidManifest.xml @@ -79,6 +79,9 @@ <activity android:name=".NewGesturesActivity" android:configChanges="keyboardHidden|orientation|screenSize" /> + <activity + android:name=".OpenMapTilesGeojsonMapActivity" + android:configChanges="keyboardHidden|orientation|screenSize" /> <activity android:name=".PathOverlayActivity" android:configChanges="keyboardHidden|orientation|screenSize" /> diff --git a/vtm-android-example/src/org/oscim/android/test/OpenMapTilesGeojsonMapActivity.java b/vtm-android-example/src/org/oscim/android/test/OpenMapTilesGeojsonMapActivity.java new file mode 100644 index 00000000..90f1c050 --- /dev/null +++ b/vtm-android-example/src/org/oscim/android/test/OpenMapTilesGeojsonMapActivity.java @@ -0,0 +1,68 @@ +/* + * Copyright 2017 devemux86 + * + * This program is free software: you can redistribute it and/or modify it under the + * terms of the GNU Lesser General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT ANY + * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A + * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License along with + * this program. If not, see <http://www.gnu.org/licenses/>. + */ +package org.oscim.android.test; + +import android.os.Bundle; + +import org.oscim.android.cache.TileCache; +import org.oscim.layers.TileGridLayer; +import org.oscim.layers.tile.buildings.BuildingLayer; +import org.oscim.layers.tile.vector.VectorTileLayer; +import org.oscim.layers.tile.vector.labeling.LabelLayer; +import org.oscim.theme.VtmThemes; +import org.oscim.tiling.source.OkHttpEngine; +import org.oscim.tiling.source.UrlTileSource; +import org.oscim.tiling.source.geojson.OpenMapTilesGeojsonTileSource; + +public class OpenMapTilesGeojsonMapActivity extends MapActivity { + + private static final boolean USE_CACHE = false; + + private TileCache mCache; + + @Override + public void onCreate(Bundle savedInstanceState) { + super.onCreate(savedInstanceState); + + UrlTileSource tileSource = OpenMapTilesGeojsonTileSource.builder() + .apiKey("xxxxxxx") // Put a proper API key + .httpFactory(new OkHttpEngine.OkHttpFactory()) + //.locale("en") + .build(); + + if (USE_CACHE) { + // Cache the tiles into a local SQLite database + mCache = new TileCache(this, null, "tile.db"); + mCache.setCacheSize(512 * (1 << 10)); + tileSource.setCache(mCache); + } + + VectorTileLayer l = mMap.setBaseMap(tileSource); + mMap.setTheme(VtmThemes.OPENMAPTILES); + + mMap.layers().add(new BuildingLayer(mMap, l)); + mMap.layers().add(new LabelLayer(mMap, l)); + + mMap.layers().add(new TileGridLayer(mMap, getResources().getDisplayMetrics().density)); + } + + @Override + protected void onDestroy() { + super.onDestroy(); + + if (mCache != null) + mCache.dispose(); + } +} diff --git a/vtm-android-example/src/org/oscim/android/test/Samples.java b/vtm-android-example/src/org/oscim/android/test/Samples.java index c404956a..d3d4ca3f 100644 --- a/vtm-android-example/src/org/oscim/android/test/Samples.java +++ b/vtm-android-example/src/org/oscim/android/test/Samples.java @@ -45,6 +45,7 @@ public class Samples extends Activity { linearLayout.addView(createButton(MapsforgeMapActivity.class)); linearLayout.addView(createButton(MapzenMvtMapActivity.class)); linearLayout.addView(createButton(MapzenGeojsonMapActivity.class)); + linearLayout.addView(createButton(OpenMapTilesGeojsonMapActivity.class)); linearLayout.addView(createLabel("Vector Features")); linearLayout.addView(createButton(MapsforgeStyleActivity.class)); diff --git a/vtm-json/src/org/oscim/tiling/source/geojson/OpenMapTilesGeojsonTileSource.java b/vtm-json/src/org/oscim/tiling/source/geojson/OpenMapTilesGeojsonTileSource.java new file mode 100644 index 00000000..f4d9fe1f --- /dev/null +++ b/vtm-json/src/org/oscim/tiling/source/geojson/OpenMapTilesGeojsonTileSource.java @@ -0,0 +1,108 @@ +/* + * Copyright 2017 devemux86 + * + * This program is free software: you can redistribute it and/or modify it under the + * terms of the GNU Lesser General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT ANY + * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A + * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License along with + * this program. If not, see <http://www.gnu.org/licenses/>. + */ +package org.oscim.tiling.source.geojson; + +import org.oscim.core.MapElement; +import org.oscim.core.Tag; +import org.oscim.tiling.source.UrlTileSource; + +import java.util.LinkedHashMap; +import java.util.Map; + +public class OpenMapTilesGeojsonTileSource extends GeojsonTileSource { + + private final static String DEFAULT_URL = "https://free-0.tilehosting.com/data/v3"; + private final static String DEFAULT_PATH = "/{Z}/{X}/{Y}.geojson"; + + public static class Builder<T extends Builder<T>> extends UrlTileSource.Builder<T> { + private String locale = ""; + + public Builder() { + super(DEFAULT_URL, DEFAULT_PATH, 1, 17); + } + + public T locale(String locale) { + this.locale = locale; + return self(); + } + + public OpenMapTilesGeojsonTileSource build() { + return new OpenMapTilesGeojsonTileSource(this); + } + } + + @SuppressWarnings("rawtypes") + public static Builder<?> builder() { + return new Builder(); + } + + private static Map<String, Tag> mappings = new LinkedHashMap<>(); + + private static Tag addMapping(String key, String val) { + Tag tag = new Tag(key, val); + mappings.put(key + "=" + val, tag); + return tag; + } + + private final String locale; + + public OpenMapTilesGeojsonTileSource(Builder<?> builder) { + super(builder); + this.locale = builder.locale; + } + + public OpenMapTilesGeojsonTileSource() { + this(builder()); + } + + public OpenMapTilesGeojsonTileSource(String urlString) { + this(builder().url(urlString)); + } + + @Override + public void decodeTags(MapElement mapElement, Map<String, Object> properties) { + boolean hasName = false; + String fallbackName = null; + + for (Map.Entry<String, Object> entry : properties.entrySet()) { + String key = entry.getKey(); + Object value = entry.getValue(); + String val = (value instanceof String) ? (String) value : String.valueOf(value); + + if (key.startsWith(Tag.KEY_NAME)) { + int len = key.length(); + if (len == 4) { + fallbackName = val; + continue; + } + if (len < 7) + continue; + if (locale.equals(key.substring(5))) { + hasName = true; + mapElement.tags.add(new Tag(Tag.KEY_NAME, val, false)); + } + continue; + } + + Tag tag = mappings.get(key + "=" + val); + if (tag == null) + tag = addMapping(key, val); + mapElement.tags.add(tag); + } + + if (!hasName && fallbackName != null) + mapElement.tags.add(new Tag(Tag.KEY_NAME, fallbackName, false)); + } +} diff --git a/vtm-playground/src/org/oscim/test/OpenMapTilesGeojsonTest.java b/vtm-playground/src/org/oscim/test/OpenMapTilesGeojsonTest.java new file mode 100644 index 00000000..3a09b51c --- /dev/null +++ b/vtm-playground/src/org/oscim/test/OpenMapTilesGeojsonTest.java @@ -0,0 +1,65 @@ +/* + * Copyright 2017 devemux86 + * + * This program is free software: you can redistribute it and/or modify it under the + * terms of the GNU Lesser General Public License as published by the Free Software + * Foundation, either version 3 of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT ANY + * WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A + * PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License along with + * this program. If not, see <http://www.gnu.org/licenses/>. + */ +package org.oscim.test; + +import org.oscim.gdx.GdxMapApp; +import org.oscim.layers.tile.buildings.BuildingLayer; +import org.oscim.layers.tile.vector.VectorTileLayer; +import org.oscim.layers.tile.vector.labeling.LabelLayer; +import org.oscim.theme.VtmThemes; +import org.oscim.tiling.source.OkHttpEngine; +import org.oscim.tiling.source.UrlTileSource; +import org.oscim.tiling.source.geojson.OpenMapTilesGeojsonTileSource; + +import java.io.File; +import java.util.UUID; + +import okhttp3.Cache; +import okhttp3.OkHttpClient; + +public class OpenMapTilesGeojsonTest extends GdxMapApp { + + private static final boolean USE_CACHE = false; + + @Override + public void createLayers() { + OkHttpClient.Builder builder = new OkHttpClient.Builder(); + if (USE_CACHE) { + // Cache the tiles into file system + File cacheDirectory = new File(System.getProperty("java.io.tmpdir"), UUID.randomUUID().toString()); + int cacheSize = 10 * 1024 * 1024; // 10 MB + Cache cache = new Cache(cacheDirectory, cacheSize); + builder.cache(cache); + } + OkHttpEngine.OkHttpFactory factory = new OkHttpEngine.OkHttpFactory(builder); + + UrlTileSource tileSource = OpenMapTilesGeojsonTileSource.builder() + .apiKey("xxxxxxx") // Put a proper API key + .httpFactory(factory) + //.locale("en") + .build(); + + VectorTileLayer l = mMap.setBaseMap(tileSource); + mMap.setTheme(VtmThemes.OPENMAPTILES); + + mMap.layers().add(new BuildingLayer(mMap, l)); + mMap.layers().add(new LabelLayer(mMap, l)); + } + + public static void main(String[] args) { + GdxMapApp.init(); + GdxMapApp.run(new OpenMapTilesGeojsonTest()); + } +} diff --git a/vtm-themes/resources/assets/vtm/openmaptiles.xml b/vtm-themes/resources/assets/vtm/openmaptiles.xml new file mode 100644 index 00000000..9b1ffb0c --- /dev/null +++ b/vtm-themes/resources/assets/vtm/openmaptiles.xml @@ -0,0 +1,1300 @@ +<?xml version="1.0" encoding="UTF-8"?> +<rendertheme xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" map-background="#fffcfa" + version="1" xmlns="http://opensciencemap.org/rendertheme" + xsi:schemaLocation="http://opensciencemap.org/rendertheme https://raw.githubusercontent.com/mapsforge/vtm/master/resources/rendertheme.xsd"> + + <!-- base style for fixed width lines --> + <style-line cap="butt" fix="true" id="fix" width="1.0" /> + + <style-text fill="#101010" id="road" k="name" priority="2" size="16" stroke="#eeeeee" + stroke-width="2.0" /> + + <style-text style="bold" fill="#101010" id="major-road" k="name" priority="1" size="16" + stroke="#eeeeee" stroke-width="2.0" /> + <style-text style="bold" fill="#606060" id="ref" k="ref" priority="2" size="12" stroke="#ffffff" + stroke-width="2.0" /> + + <style-text caption="true" dy="20" fill="#404000" id="poi" k="name" size="16" stroke="#aaffffff" + stroke-width="2.0" /> + + <style-area fade="11" fill="#e8e7e3" id="residential" /> + + <style-area fade="10" fill="#e6e3e5" id="railway|industrial" /> + + + <!-- fade out at z=7, blend over to 'blend-fill' in z=11 --> + <!-- src="assets:textures/wood.png" --> + <!-- <style-area id="wood" fill="#d1dbc7" fade="8" blend="11" blend-fill="#9ac56e" /> --> + + <style-area id="tex1" src="assets:textures/rough.png" /> + + <!-- meadow|garden --> + <style-area fade="10" fill="#c9dc91" id="greens" use="tex1" /> + + <!-- grass --> + <style-area fade="12" fill="#d3dcb9" id="lightgreen" use="tex1" /> + + <!-- grassland|scrub --> + <style-area fade="10" fill="#c2cba5" id="darkgreen" use="tex1" /> + + <style-area fade="12" fill="#e4dab5" id="farmland" stroke="#d1dbc7" stroke-width="1.0" + use="tex1" /> + + <!-- <style-area id="greens" fill="#d2e5ce" fade="10" /> --> + + <!-- marsh|wetland|mud|nature_reserve --> + <style-area fade="12" fill="#deecb9" id="greens2" /> + + <!-- park|common|green|cemetery|golf_course|dog_park --> + <style-area fade="11" fill="#9ac56e" id="park" use="tex1" /> + <!-- <style-area id="wood" use="park" fill="#9ac56e" fade="8" stroke="#d1dbc7" stroke-width="1.0"/> --> + + <style-area blend="11" blend-fill="#83aa5b" fade="8" fill="#b3d095" id="wood" use="park" /> + <!-- <style-line id="wood" fix="true" cap="butt" width="1.0" stroke="#9ac56e" /> --> + + <!-- <style-area id="park" fill="#a3ca7b" fade="11" /> --> + <style-line cap="butt" fade="14" fix="true" id="park" stroke="#9ac56e" width="1.0" /> + + <!-- de:Kleingartengebiet --> + <style-area fade="12" fill="#efeae0" id="allotments" use="tex1" /> + + <!-- de:Steinbruch, Schotter-, Kies-, Sand- und Tongrube --> + <style-area fade="10" fill="#ddddcc" id="quarry" /> + <style-area fade="10" fill="#eeedea" id="military" /> + <style-line id="residential" stroke="#ffffff" width="1.3" /> + <style-line cap="square" id="residential:bridge" use="residential" /> + + <!-- when inheriting another style with 'from' then 'width' is relative to the parent --> + <style-line id="pedestrian" use="residential" width="-0.4" /> + <style-line cap="square" id="pedestrian:bridge" use="pedestrian" /> + <style-line id="highway:z11" stroke="#fcba5a" width="1.8" /> + <!-- <style-line id="highway:z11:bridge" use="highway:z11" cap="butt" /> --> + <style-line cap="butt" id="trunk_link" stroke="#fee16e" width="1.3" /> + <style-line id="trunk" stroke="#fedb52" width="1.6" /> + <style-line id="primary:z11" stroke="#f4d26e" width="1.5" /> + <style-line id="secondary:z11" use="primary:z11" width="-0.1" /> + <style-line id="tertiary" stroke="#fefefa" use="residential" width="0.2" /> + <style-line id="construction" stroke="#e0e0e0" width="1.2" /> + <style-line id="highway-service" use="residential" width="-0.6" /> + + <!-- track|footway|path|cycleway --> + <style-line cap="butt" fix="true" id="footway" stipple="2" stipple-stroke="#d35c48" + stipple-width="0.6" stroke="#aaffffff" width="1.8" /> + <style-line id="highway:cycleway" stipple-stroke="#4040ee" use="footway" width="0.1" /> + <style-line id="highway:track" stipple="3" stipple-stroke="#a39b68" use="footway" width="0.1" /> + <style-line id="highway:path" stipple="2" stipple-stroke="#837b58" use="footway" width="0.1" /> + + <!-- <style-line id="footway:z16" use="footway" width="-0.95" fixed="false" fade="-1"/> --> + <style-line id="footway:z17" stroke="#faf8f5" width="0.3" /> + + <!-- de: ein Weg der für Reiter vorgeshen ist.. --> + <style-line cap="butt" id="bridleway" stipple-stroke="#837b58" stroke="#d3cb98" use="footway" + width="0.1" /> + <style-line cap="butt" fix="true" id="steps" stipple="2" stipple-stroke="#be6253" + stipple-width="1.0" stroke="#aaffffff" width="4.2" /> + <style-line cap="butt" fix="true" id="water:outline" stroke="#a4bbcc" width="1.0" /> + + <style-line cap="butt" fix="true" id="water" stroke="#a4bbcc" width="1.0" /> + <style-line fix="false" id="river" stroke="#a4bbcc" use="water" /> + + <!--<style-area id="water" fill="#97b7e5" afc5e3 /> --> + <!-- src="assets:textures/water.png" --> + <style-area fade="-1" fill="#99badf" id="water" use="tex1" /> + + <!-- no-go area boundary --> + <style-line cap="butt" fix="true" id="fence" stroke="#444444" width="1.2" /> + <style-line cap="butt" id="aeroway:runway" stroke="#c8ccbe" width="1.8" /> + + <!-- <style-line id="building" stroke="#c9c3c1" width="1.0" fix="true" cap="butt" fade="15"/> --> + <!-- <style-line id="building" stroke="#d0cec8" width="1.0" fix="true" cap="butt" fade="15"/> + <style-area id="building" fill="#e9e6e3" fade="15"/> --> + + <style-line fade="15" id="building" stroke="#eeb7b6b3" use="fix" /> + <style-area fade="15" fill="#f2f0eb" id="building" stroke="#b7b6b3" stroke-width="1.0" /> + + <m e="way" k="natural" v="issea|sea"> + <area mesh="true" use="water" /> + </m> + + <m e="way" k="natural" v="nosea"> + <area fill="#f8f8f8" mesh="true" /> + </m> + + <!-- all closed ways that are not 'highway' or 'building' --> + + <m closed="yes" e="way" k="highway|building" v="~"> + + <!-- landuse base --> + <m k="landuse"> + <m v="urban"> + <area fill="#f4f3f0" /> + </m> + + <m v="meadow|conservation"> + <area fade="11" use="greens" /> + </m> + + <m v="residential|commercial|retail|farmyard"> + <area use="residential" /> + </m> + </m> + <m k="natural" v="grassland|scrub"> + <area use="darkgreen" /> + </m> + + <m k="landuse"> + <m v="farmland|farm|orchard|vineyard|greenhouse_horticulture|plant_nursery"> + <area use="farmland" /> + </m> + <m v="quarry"> + <area use="quarry" /> + </m> + <!-- <m v="farmyard|retail|commercial|industrial;retail"> + <area use="residential" /> + </m> --> + <m v="industrial|railway"> + <area use="railway|industrial" /> + </m> + <!-- <m v="military"> + <area use="military"/> + </m> --> + <!--<m k="landuse" v="construction|greenfield"> <area fill="#a47c41" + stroke="#e4e4e4" width="0.2" /> </m> --> + <!-- <m k="landuse" v="garages"> <area fill="#d6d6e4" /> </m> --> + </m> + <m k="landuse|natural|leisure|amenity|tourism"> + <!-- kind of more like landuse imho --> + <m k="leisure|landuse" v="nature_reserve"> + <area use="greens2" /> + <m zoom-min="14"> + <line cap="butt" fix="true" stroke="#abe29c" width="1.0" /> + </m> + </m> + + <!-- tourism areas + Berlin Zoologischer Garten has lots of details that should be drawn above + --> + <m k="tourism"> + <!-- <m k="tourism" v="attraction"> <area fill="#f2caea" /> </m> --> + + <m v="zoo|picnic_site|caravan_site|camp_site"> + <area fill="#c0d69a" /> + </m> + </m> + + <!-- amenity --> + <m k="amenity" zoom-min="14"> + <m v="kindergarten|school|college|university"> + <!-- <area fill="#cdabde" /> --> + <area fade="14" fill="#e6e4c5" /> + <line cap="butt" fade="14" fix="true" stroke="#9aabae" width="1.0" /> + </m> + <m v="hospital"> + <area fill="#f2d9b1" /> + </m> + <!-- <m v="parking" zoom-min="15"> + <area fill="#f4f4f4" stroke="#d4d4d4" stroke-width="0.2" /> + </m> + <m v="fountain" closed="yes"> + <area fill="#b4cbdc" stroke="#000080" stroke-width="0.15" /> + </m> --> + </m> + + <!-- landuse --> + <m k="landuse" zoom-min="11"> + <!-- how about 'leisure' for this one? --> + <m v="cemetery"> + <area use="park" /> + <m zoom-min="14"> + <line use="park" /> + </m> + </m> + </m> + <m k="landuse" v="village_green|recreation_ground"> + <area use="greens" /> + </m> + <m k="landuse" v="allotments" zoom-min="12"> + <area use="allotments" /> + </m> + <m k="leisure" v="park|common|green|golf_course" zoom-min="11"> + <area use="park" /> + <m zoom-min="14"> + <line use="park" /> + </m> + <!-- <text use="park" /> --> + </m> + + <!-- Heideland, keep below forest --> + <m v="heath|sand" zoom-min="10"> + <area fade="10" fill="#fffad1" use="tex1" /> + </m> + + <m k="landuse|natural" v="forest|wood"> + <m zoom-max="13" zoom-min="8"> + <area use="wood" /> + </m> + <m zoom-min="14"> + <area stroke="#91bf63" stroke-width="1.0" use="wood" /> + </m> + </m> + + <!-- keep grass above forest:wood and leisure:park! --> + <!-- http://wiki.openstreetmap.org/wiki/Proposed_features/conservation, + often serves as background for leisure=nature_reserve --> + <m k="landuse" v="grass"> + <area use="lightgreen" /> + </m> + + <m k="leisure" v="garden"> + <area use="greens" /> + </m> + + <!-- amenity --> + <m k="amenity"> + <!--<m v="kindergarten|school|college|university" zoom-min="15"> + <area fill="#cdbbca" fade="15"/> + <line stroke="#9aabae" width="1.0" fix="true" cap="butt" fade="15"/> + </m> + + <m v="hospital" zoom-min="14"> + <area fill="#e6e4c5" /> + </m> + --> + <m v="parking" zoom-min="15"> + <area fill="#f4f4f4" stroke="#d4d4d4" stroke-width="0.2" /> + <m zoom-min="17"> + <symbol src="assets:symbols/transport/parking.svg" /> + </m> + </m> + <m closed="yes" v="fountain"> + <area fill="#b4cbdc" stroke="#000080" stroke-width="0.15" /> + </m> + + </m> + + <!-- <m k="natural" v="coastline"> + <line stroke="#a4bbcc" width="1.2" fix="true" /> + </m> --> + + <!-- natural --> + <m k="natural" zoom-min="10"> + <m v="glacier"> + <area fill="#fafaff" /> + </m> + <m v="land"> + <area fill="#f8f8f8" /> + </m> + <m v="beach"> + <area fill="#f7f5c8" /> + </m> + <m v="marsh|wetland|mud"> + <area use="greens2" /> + </m> + </m> + + <!-- leisure --> + <m k="leisure" zoom-min="13"> + + <m v="stadium"> + <line cap="butt" fix="true" stroke="#c9c3c1" width="1.0" /> + <area fill="#e9e6e3" /> + </m> + + <!--should be under playing field --> + <m v="sports_centre|water_park" zoom-min="14"> + <area fade="12" fill="#daefdb" /> + </m> + <m v="playground|miniature_golf" zoom-min="15"> + <area fill="#f4f4de" use="tex1" /> + <line cap="butt" fix="true" stroke="#d9d9a3" width="1.0" /> + </m> + <m v="playing_fields|pitch"> + <area fill="#f4f4de" /> + <line cap="butt" fix="true" stroke="#d9d9a3" width="1.0" /> + </m> + <m v="swimming_pool"> + <area fill="#d4ebfc" stroke="#6060ff" stroke-width="0.2" /> + </m> + + <!-- <m v="track"> <m k="area" v="yes|true"> + <area fill="#c9d8a2" stroke="#b7c690" width="0.025" /> </m> <m + e="way" k="area" v="~|no|false"> <line stroke="#b7c690" width="0.75" + /> </m> </m> --> + </m> + + <!-- area outlines need to be above to avoid uggly pixelation where + not aliased polygon overlaps the lines... --> + <m k="leisure|landuse" zoom-min="14"> + + <m v="nature_reserve"> + <line cap="butt" fix="true" stroke="#abe29c" width="1.0" /> + </m> + <m v="military"> + <line use="fence" /> + </m> + </m> + <m k="landuse" v="reservoir|basin"> + <area use="water" /> + </m> + + <!-- ...should rewrite tag to: highway=leisure/sport=* imho --> + <m k="leisure" v="track"> + <line cap="butt" fix="true" stroke="#c1bcb6" width="1.3" /> + </m> + </m><!-- end landuse|natural|leisure||amenity|tourism --> + </m> + + <!-- waterways --> + <m e="way" k="waterway"> + <m v="ditch|drain" zoom-min="14"> + <line fade="14" use="water" width="0.2" /> + </m> + <m v="canal"> + <line use="river" width="-0.3" /> + </m> + <m v="stream" zoom-min="13"> + <line fade="13" use="water" width="0.5" /> + </m> + <m select="first" v="river"> + <m zoom-min="12"> + <line use="river" width="0.3" /> + </m> + <!-- zoom <= 11 --> + <m k="rank" v="~|-1" zoom-min="9"> + <line fade="9" use="water" width="0.2" /> + </m> + <m k="rank" v="0|1|2"> + <line fade="2" use="water" width="0.3" /> + </m> + <m k="rank" v="3" zoom-min="3"> + <line fade="3" use="water" width="0.3" /> + </m> + <m k="rank" v="4" zoom-min="4"> + <line fade="4" use="water" width="0.3" /> + </m> + <m k="rank" v="5" zoom-min="5"> + <line fade="5" use="water" width="0.3" /> + </m> + <m k="rank" v="6" zoom-min="6"> + <line fade="6" use="water" width="0.2" /> + </m> + <m k="rank" v="7" zoom-min="7"> + <line fade="7" use="water" width="0.2" /> + </m> + <m k="rank" v="8" zoom-min="8"> + <line fade="8" use="water" width="0.1" /> + </m> + <m k="rank" v="9" zoom-min="9"> + <line fade="9" use="water" width="0.1" /> + </m> + </m> + <m v="riverbank|dock"> + <area use="water" /> + <line use="water:outline" /> + </m> + <m v="weir"> + <line stroke="#000088" use="fix" /> + </m> + <m v="dam" zoom-min="12"> + <line stroke="#ababab" use="fix" width="0.2" /> + </m> + <m k="lock" v="yes|true"> + <line stroke="#f8f8f8" use="fix" width="0.5" /> + </m> + </m> + + <m e="way"> + <m closed="yes" k="natural" v="water"> + <area use="water" /> + <caption area-size="0.4" fill="#404000" k="name" size="16" stroke="#aaffffff" + stroke-width="2.0" /> + <!--<line use="water:outline" />--> + </m> + + <!-- sport --> + <!-- <m k="sport"> <m k="sport" v="soccer" + zoom-min="17"> <m k="sport" v="swimming|canoe|diving|scuba_diving"> + <area fill="#b4cbdc" stroke="#6060ff" width="0.2" /> </m> <m + e="way" k="sport" v="tennis"> <area fill="#d18a6a" stroke="#b36c4c" width="0.2" + /> </m> </m> --> + + <!-- outline 0 --> + <outline-layer blur="1.0" id="glow" stroke="#000000" width="0.2" /> + <outline-layer id="0" stroke="#44000000" width="0.1" /> + + <!-- match tunnel-tag (to ensure tunnel key is present) --> + <m k="tunnel" zoom-min="11"> + <!-- match tunnel-tag that are not 'no' or 'false' --> + <m k="tunnel" v="-|no|false"> + <!-- match area-tag that are 'no' or 'false' or not present --> + <m k="area" v="~|no|false"> + <!-- highway tunnels --> + <m k="highway"> + <m zoom-min="16"> + <m v="steps"> + <line use="steps" /> + <!-- <outline use="0"/> --> + </m> + <!-- <m v="track|footway|path|cycleway" zoom-min="16"> + <line use="footway:z16"/> + </m> --> + </m> + <m zoom-min="14"> + <m v="footway"> + <line use="footway" /> + </m> + <m v="cycleway"> + <line use="highway:cycleway" /> + </m> + <m v="track"> + <line use="highway:track" /> + </m> + <m v="path"> + <line use="highway:path" /> + </m> + <m v="bridleway"> + <line use="bridleway" /> + </m> + <m v="construction"> + <outline use="0" /> + <line outline="0" use="construction" /> + </m> + <m v="service"> + <m k="service" v="~|parking_aisle"> + <line outline="0" use="highway-service" /> + </m> + </m> + </m> + <m v="trunk_link|motorway_link"> + <line outline="0" use="trunk_link" /> + <text use="major-road" /> + </m> + <m zoom-min="13"> + <m v="byway|pedestrian"> + <line outline="0" use="pedestrian" /> + <text use="road" /> + </m> + <m v="residential|road|unclassified|living_street"> + <line outline="0" use="residential" /> + <text use="road" /> + </m> + </m> + <m v="tertiary|secondary_link"> + <line outline="0" use="tertiary" /> + <text use="road" /> + </m> + <m v="secondary|primary_link"> + <line outline="0" use="secondary:z11" /> + <text use="major-road" /> + </m> + <m v="primary"> + <line outline="0" use="primary:z11" /> + <text use="major-road" /> + <text use="ref" /> + </m> + <m v="trunk"> + <line blur="0.3" outline="0" use="trunk" /> + <!-- <outline use="glow"/> --> + <text use="major-road" /> + <text use="ref" /> + </m> + <m v="motorway"> + <line blur="0.3" outline="0" use="highway:z11" /> + <!-- <outline use="glow"/> --> + <text use="major-road" /> + <text use="ref" /> + </m> + </m> + <!-- railway tunnel --> + <m k="railway"> + <!-- <m v="tram|subway|light_rail|narrow_gauge"> + <line stroke="#a0a0a0" width="0.8" cap="butt" fix="true"/> + </m> --> + <m v="rail"> + <line cap="butt" fix="true" stroke="#aa888888" width="0.9" /> + </m> + </m> + </m> + </m> + </m><!-- end tunnel --> + + <!-- platform cores --> + <m k="highway|railway|public_transport" v="platform"> + <m closed="yes"> + <area fill="#dbdbc9" /> + </m> + <m closed="no"> + <line stroke="#dbdbc9" width="0.3" /> + </m> + </m> + + <!-- runways areas --> + <m k="aeroway"> + <m closed="yes" v="aerodrome"> + <m zoom-min="12"> + <area fill="#e8ecde" /> + </m> + <m zoom-max="11"> + <caption dy="18" fill="#000000" k="ref" priority="5" size="19" stroke="#ffffff" + stroke-width="2.0" /> + </m> + <m zoom-min="12"> + <caption area-size="0.1" dy="18" fill="#000000" k="name" priority="5" size="19" + stroke="#ffffff" stroke-width="2.0" /> + </m> + <symbol src="assets:symbols/transport/airport2.svg" /> + </m> + <!-- A place where planes are parked --> + <m v="apron"> + <area fill="#f0f0f0" /> + </m> + <!-- Airport passenger building --> + <m v="terminal|hangar"> + <area use="building" /> + </m> + </m> + + <!-- turning circles --> + <!-- <m k="highway" v="turning_circle"> <circle radius="1.5" scale-radius="true" + fill="#707070" /> + </m> --> + + <!-- building --> + <m k="building"> + <m zoom-min="14"> + <m closed="yes"> + <area fade="14" use="building" /> + </m> + <m closed="no"> + <line fade="14" use="building" /> + </m> + </m> + <m zoom-min="17"> + <extrusion line-color="#ffd9d8d6" side-color="#eaecebe9" top-color="#eaf9f8f6" /> + </m> + <m zoom-min="17"> + <caption style="bold" fill="#4040ff" k="name" priority="9" size="14" + stroke="#ffffff" stroke-width="2.0" /> + <caption style="bold" fill="#606060" k="addr:housenumber" priority="10" size="12" + stroke="#ffffff" stroke-width="2.0" /> + </m> + </m> + + <!-- outline 1 - 4 --> + <outline-layer id="1" stroke="#aa807040" width="0.1" /> + <!-- <outline-layer id="1" stroke="#404030"/> --> + <outline-layer id="2" stroke="#c0c0c0" width="0.1" /> + <outline-layer id="primary" stroke="#aa7f7700" width="0.1" /> + <outline-layer id="motorway" stroke="#aa805f2e" width="0.1" /> + + <!-- highway --> + <m k="highway"> + <m select="first" zoom-max="5" zoom-min="4"> + <m k="area" v="~|no|false"> + <!-- <m v="secondary|primary_link" zoom-min="9"> + <line stroke="#f2df6d" width="1.3" cap="butt" fix="true" fade="9"/> + </m> --> + + <m v="route_primary" zoom-min="3"> + <line cap="butt" fade="5" fix="true" stroke="#c6c5a2" width="1.2" /> + </m> + <m v="route_trunk" zoom-min="3"> + <line cap="butt" fade="5" fix="true" stroke="#deb683" width="1.3" /> + </m> + <m v="route_motorway"> + <line cap="butt" fade="5" fix="true" stroke="#deb683" width="1.4" /> + </m> + </m> + </m> + <m select="first" zoom-max="7" zoom-min="5"> + <m k="area" v="~|no|false"> + <m v="secondary|primary_link" zoom-min="9"> + <line fade="9" stroke="#e2cf5d" use="fix" width="0.3" /> + </m> + <m v="trunk_link|motorway_link" zoom-min="8"> + <line fade="8" stroke="#eec693" use="fix" width="0.4" /> + </m> + <m v="primary" zoom-min="5"> + <line fade="5" stroke="#c6c5a2" use="fix" width="0.5" /> + </m> + <m v="trunk" zoom-min="5"> + <line fade="5" stroke="#c6c5a2" use="fix" width="0.5" /> + </m> + <m v="motorway"> + <line fade="4" stroke="#deb683" use="fix" width="0.6" /> + </m> + </m> + </m> + <m zoom-min="8"> + <!-- when tunnel|bridge is present it must be 'no' --> + <m k="tunnel|bridge" v="~|no"> + <!-- highway area --> + + <m k="area" v="yes|true"> + <m v="footway" zoom-min="15"> + <area fill="#fefefe" /> + <line cap="butt" fix="true" stroke="#c0c0c0" width="1.0" /> + </m> + + <m v="pedestrian|service|unclassified|residential|road|living_street" + zoom-min="13"> + <area fill="#ffffff" /> + <line cap="butt" fix="true" stroke="#d0d0d0" width="1.0" /> + </m> + + <!-- <m v="path" zoom-min="14"> + <area fill="#d0d0d0" /> + </m> --> + </m> + + <m k="area" v="~|no|false"> + <m zoom-min="16"> + <m v="steps"> + <line use="steps" /> + <!-- <outline use="2"/> --> + </m> + <!-- <m v="track|footway|path|cycleway" zoom-min="16" zoom-max="16"> + <line use="footway:z16"/> + </m> --> + <m v="track|footway|path|cycleway" zoom-min="17"> + <line outline="1" use="footway:z17" /> + </m> + </m> + <m zoom-min="14"> + <m v="footway"> + <line use="footway" /> + </m> + <m v="cycleway"> + <line use="highway:cycleway" /> + </m> + <m v="track"> + <line use="highway:track" /> + </m> + <m v="path"> + <line use="highway:path" /> + </m> + <m v="bridleway"> + <line use="bridleway" /> + </m> + <m v="construction"> + <line outline="1" use="construction" /> + </m> + <m v="service"> + <!-- matches every service but parking_isle --> + <m k="service" v="-|parking_aisle"> + <line outline="1" use="highway-service" /> + </m> + <m k="service" v="parking_aisle" zoom-min="16"> + <line outline="1" use="highway-service" width="-0.4" /> + </m> + </m> + </m> + <m v="trunk_link|motorway_link"> + <line outline="motorway" use="trunk_link" /> + <text use="major-road" /> + </m> + <m zoom-min="13"> + <m v="byway|pedestrian"> + <line outline="1" use="residential" width="-0.4" /> + <text use="road" /> + </m> + + </m> + <m v="residential|road|unclassified|living_street"> + <line outline="1" use="residential" /> + <text use="road" /> + </m> + <m v="tertiary|secondary_link"> + <line outline="1" use="tertiary" /> + <text use="road" /> + </m> + <m v="secondary|primary_link"> + <line outline="primary" use="secondary:z11" /> + <text use="major-road" /> + </m> + <m v="primary"> + <line outline="primary" use="primary:z11" /> + <text use="major-road" /> + <text use="ref" /> + </m> + <m v="trunk"> + <line outline="motorway" use="trunk" /> + <text use="major-road" /> + <text use="ref" /> + </m> + <m v="motorway"> + <line outline="motorway" use="highway:z11" /> + <text use="major-road" /> + <text use="ref" /> + </m> + </m> <!-- end area=~|no|false --> + </m><!-- end tunnel|bridge=~|no|false --> + + <!-- Bridge casings should be above other roads --> + <outline-layer id="bridge" stroke="#aa202020" width="0.08" /> + + <!-- muse contain bridge --> + <m k="bridge"> + <!-- except bridge=no|false --> + <m k="bridge" v="-|no|false"> + + <!-- no areas --> + <m k="area" v="~|no|false"> + + <m zoom-min="16"> + <m v="steps"> + <line use="steps" /> + <!-- <outline use="bridge"/> --> + </m> + </m> + + <m v="track|footway|path|cycleway" zoom-min="15"> + <line cap="butt" outline="bridge" use="footway:z17" /> + </m> + + <m select="first" zoom-min="14"> + <m v="footway"> + <line use="footway" /> + </m> + <m v="cycleway"> + <line use="highway:cycleway" /> + </m> + <m v="track"> + <line use="highway:track" /> + </m> + <m v="path"> + <line use="highway:path" /> + </m> + <m v="bridleway"> + <line use="bridleway" /> + </m> + <m v="construction"> + <line cap="square" outline="bridge" use="construction" /> + </m> + <m v="service"> + <line cap="square" outline="bridge" use="highway-service" /> + </m> + </m> + + <m select="first" zoom-min="13"> + <m v="byway|pedestrian"> + <line outline="bridge" use="pedestrian:bridge" /> + <text use="road" /> + </m> + <m v="residential|road|unclassified|living_street"> + <line outline="bridge" use="residential:bridge" /> + <text use="road" /> + </m> + </m> + + <m select="first"> + <m v="tertiary|secondary_link"> + <line cap="square" outline="bridge" use="tertiary" /> + <text use="road" /> + </m> + <m v="trunk_link|motorway_link"> + <line cap="square" outline="bridge" use="trunk_link" /> + <text use="major-road" /> + </m> + <m v="secondary|primary_link"> + <line cap="square" outline="bridge" use="secondary:z11" /> + <text use="major-road" /> + </m> + <m v="primary"> + <line cap="square" outline="bridge" use="primary:z11" /> + <text use="major-road" /> + <text use="ref" /> + </m> + <m v="trunk"> + <line cap="square" outline="bridge" use="trunk" /> + <text use="major-road" /> + <text use="ref" /> + </m> + <m v="motorway"> + <line cap="square" outline="bridge" use="highway:z11" /> + <text use="major-road" /> + <text use="ref" /> + </m> + </m> + </m><!-- end area=~|no|false --> + + + <m k="area" select="first" v="yes|true"> + <m v="footway" zoom-min="15"> + <area fill="#fefefe" /> + <line cap="butt" stroke="#c0c0c0" width="0.15" /> + </m> + <m v="pedestrian|service|unclassified|residential|road|living_street" + zoom-min="13"> + <area fill="#eeffffff" /> + <line cap="butt" fix="true" stroke="#c0c0c0" width="1.0" /> + </m> + </m> <!-- end area=yes|true --> + </m> <!-- end bridge=yes --> + </m> + </m> <!-- end zoom-min=11 --> + </m><!-- end highway --> + + <!-- runways cores --> + <m k="aeroway"> + <m v="runway"> + <line use="aeroway:runway" /> + </m> + <m v="taxiway"> + <line use="aeroway:runway" width="-0.8" /> + </m> + </m> + + <!-- man_made features --> + <m k="man_made" v="pier"> + <m closed="no"> + <line cap="butt" stroke="#d0d0d0" width="0.4" /> + <line cap="butt" stroke="#e4e4e4" width="0.3" /> + </m> + <m closed="yes"> + <area fill="#e4e4e4" stroke="#d0d0d0" stroke-width="1.05" /> + </m> + </m> + + <!-- barriers --> + <m k="barrier"> + <!-- <m v="fence|wall|city_wall" zoom-min="15"> <line + stroke="#909090" width="0.1" cap="butt" /> </m> --> + <m v="retaining_wall" zoom-min="15"> + <line cap="butt" fix="true" stroke="#888888" width="1.1" /> + </m> + </m> + + + <!-- railway (no tunnel) --> + <m k="railway" zoom-min="12"> + <m k="tunnel" v="~|false|no"> + + <m v="station"> + <area fill="#dbdbc9" stroke="#707070" stroke-width="0.3" /> + </m> + + <!-- railway bridge casings --> + <m zoom-min="14"> + <m k="bridge" v="yes|true"> + <m v="tram"> + <line cap="butt" fix="true" stroke="#777777" width="0.9" /> + </m> + <m v="subway|light_rail|narrow_gauge"> + <line cap="butt" fix="true" stroke="#777777" width="0.9" /> + </m> + <m v="rail"> + <line cap="butt" fix="true" stroke="#777777" width="0.9" /> + </m> + </m> + </m> + + <!-- railway casings and cores --> + <m v="tram" zoom-min="15"> + <line fix="true" stroke="#887766" width="1.0" /> + </m> + <m v="light_rail|subway|narrow_gauge" zoom-min="14"> + <line cap="butt" fix="true" stroke="#a0a0a0" width="0.9" /> + </m> + <m v="rail|turntable" zoom-max="14"> + <line cap="butt" fade="12" fix="true" stroke="#ddaa9988" width="1.0" /> + </m> + <m v="rail|turntable" zoom-min="15"> + <line cap="butt" fade="12" fix="true" stipple="10" stipple-stroke="#ffffff" + stipple-width="0.8" stroke="#aaa6a4" width="2.0" /> + </m> + + <!-- <m v="rail" zoom-max="14" zoom-min="13"> + <line stroke="#8888aa" width="0.6" cap="butt" + fix="true" /> + </m> --> + <!-- <m v="rail" zoom-max="13" zoom-min="11"> + <line stroke="#bbbbcc" width="0.8" cap="butt" fix="true" /> + </m> --> + <!-- whatever railway:spur means ... --> + <m v="disused|spur|abandoned|preserved"> + <line cap="butt" fade="12" fix="true" stroke="#cccccc" width="0.8" /> + </m> + </m> + </m> + + <!-- non-physical boundaries --> + <!-- <m k="boundary"> <m k="boundary" v="national_park"> + <line stroke="#4ef94b" width="0.25" stroke-dasharray="15, 5, 5, 5" + /> --> + + <!-- + maybe use some alpha texture for this + <m k="boundary" v="national_park"> + <area fill="#d7e6b0" /> + </m> + --> + + <!--<m k="boundary" v="administrative"> --> + <m k="admin_level"> + <m v="4"> + <line fix="true" stipple="4" stipple-stroke="#888888" stipple-width="1.0" + stroke="#dadada" width="1.3" /> + </m> + <m v="2"> + <line fix="true" stipple="6" stipple-stroke="#647b9c" stipple-width="1.0" + stroke="#dadada" width="1.6" /> + </m> + </m> + <!-- </m> --> + + <!-- historic --> + <!-- <m k="historic" v="ruins" zoom-min="17"> + <caption k="name" style="bold" size="10" fill="#4040ff" stroke="#ffffff" stroke-width="2.0" + /> + </m> --> + + <!-- place --> + <m k="place" v="locality" zoom-min="17"> + <caption style="bold" fill="#000000" k="name" size="12" stroke="#ffffff" + stroke-width="2.0" /> + </m> + + <m k="highway" v="track"> + <m k="area" v="yes"> + <area fill="#aaff0000" /> + </m> + </m> + + <!-- highway one-way markers --> + <m k="tunnel" v="~|false|no"> + <m k="area" v="~|false|no"> + <m k="highway"> + <m k="oneway" v="yes|true" zoom-min="16"> + <line fix="true" src="assets:patterns/oneway.svg" stipple="160" + stipple-stroke="#666666" width="6" /> + </m> + </m> + </m> + </m> + + </m><!-- end e="way" --> + + <m e="node" select="first"> + + <m k="barrier"> + <m zoom-min="10"> + <m v="bollard"> + <circle fill="#909090" radius="1.5" /> + </m> + <m v="block"> + <circle fill="#909090" radius="1.5" /> + </m> + <m v="gate"> + <circle fill="#909090" radius="1.5" /> + </m> + <m v="lift_gate"> + <circle fill="#909090" radius="1.5" /> + </m> + </m> + </m> + + <m k="highway"> + <m v="bus_stop" zoom-min="16"> + <symbol src="assets:symbols/dot_blue.svg" /> + </m> + <m v="traffic_signals" zoom-min="17"> + <symbol src="assets:symbols/transport/traffic_lights.svg" /> + </m> + <m v="turning_circle"> + <circle fill="#ffffff" radius="1.4" scale-radius="true" /> + </m> + </m> + + <!-- historic --> + <m k="historic"> + <symbol src="assets:symbols/tourist/monument.svg" /> + + <m zoom-min="17"> + <text use="poi" /> + </m> + </m> + + <!-- place --> + <m k="place"> + <m v="locality" zoom-min="13"> + <caption style="bold" fill="#606060" k="name" priority="5" size="14" + stroke="#ffffff" stroke-width="2.0" /> + </m> + <m v="suburb" zoom-max="14"> + <caption style="bold_italic" fill="#404040" k="name" priority="4" size="17" + stroke="#ffffff" stroke-width="2.0" /> + </m> + <m v="village" zoom-max="14"> + <caption fill="#444411" k="name" priority="3" size="17" stroke="#ffffff" + stroke-width="2.0" /> + </m> + <m v="island" zoom-min="10"> + <caption style="bold" fill="#000000" k="name" priority="1" size="20" + stroke="#ffffff" stroke-width="2.0" /> + </m> + <m v="town"> + <caption fill="#000000" k="name" priority="2" size="19" stroke="#ffffff" + stroke-width="2.0" /> + </m> + <m v="city"> + <m zoom-min="7"> + <caption style="bold" dy="14" fill="#000000" k="name" priority="1" size="19" + stroke="#ffffff" stroke-width="2.0" symbol="assets:symbols/dot_black.svg" /> + </m> + <m zoom-max="6"> + <caption dy="14" fill="#000000" k="name" priority="1" size="19" stroke="#ffffff" + stroke-width="2.0" symbol="assets:symbols/dot_black.svg" /> + </m> + </m> + <m v="country"> + <caption style="bold" fill="#000000" k="name" priority="0" size="20" + stroke="#ffffff" stroke-width="2.0" /> + </m> + </m> + + <!-- railway --> + <m k="railway"> + <m v="station" zoom-min="14"> + <symbol src="assets:symbols/transport/train_station2.svg" /> + <caption style="bold" dy="-20" fill="#ec2d2d" k="name" size="14" stroke="#ffffff" + stroke-width="2.0" /> + </m> + + <m v="halt|tram_stop"> + <symbol src="assets:symbols/transport/tram_stop.svg" /> + <caption style="bold" dy="-20" fill="#ec2d2d" k="name" size="14" stroke="#ffffff" + stroke-width="2.0" /> + </m> + <m v="level_crossing"> + <symbol src="assets:symbols/railway-crossing.svg" /> + </m> + </m> + + <!-- aeroway --> + <m k="aeroway"> + <m v="helipad" zoom-min="16"> + <symbol src="assets:symbols/transport/helicopter.svg" /> + </m> + <m v="aerodrome|airport" zoom-min="9"> + <symbol src="assets:symbols/transport/airport2.svg" /> + </m> + </m> + + <m k="amenity"> + + <m select="first" zoom-min="15"> + <m v="hospital"> + <symbol src="assets:symbols/health/hospital.svg" /> + </m> + <m v="school"> + <symbol src="assets:symbols/education/school.svg" /> + </m> + <m v="university|college"> + <symbol src="assets:symbols/education/university.svg" /> + </m> + <m v="library"> + <symbol src="assets:symbols/amenity/library.svg" /> + </m> + <m v="cinema"> + <symbol src="assets:symbols/tourist/cinema2.svg" /> + </m> + + <m select="when-matched"> + <text use="poi" /> + </m> + </m> + + <m select="first" zoom-min="16"> + <m v="atm" zoom-min="17"> + <symbol src="assets:symbols/money/atm2.svg" /> + </m> + <m v="cafe"> + <symbol src="assets:symbols/food/cafe.svg" /> + </m> + <m v="pub"> + <symbol src="assets:symbols/food/pub.svg" /> + </m> + <m v="bar"> + <symbol src="assets:symbols/food/bar.svg" /> + </m> + <m v="fast_food"> + <symbol src="assets:symbols/food/fastfood.svg" /> + </m> + <m v="restaurant"> + <symbol src="assets:symbols/food/restaurant.svg" /> + </m> + <m v="bus_station"> + <symbol src="assets:symbols/transport/bus_station.svg" /> + </m> + <m select="when-matched"> + <text use="poi" /> + </m> + </m> + + <m select="first" zoom-min="17"> + <m v="bank"> + <symbol src="assets:symbols/money/bank2.svg" /> + </m> + <!--<m v="bench"> + <symbol src="assets:symbols/bench.svg" /> + </m>--> + <m v="bicycle_rental"> + <symbol src="assets:symbols/transport/rental_bicycle.svg" /> + </m> + <m v="drinking_water"> + <symbol src="assets:symbols/food/drinkingtap.svg" /> + </m> + <m v="fire_station"> + <symbol src="assets:symbols/amenity/firestation3.svg" /> + </m> + <m v="fountain"> + <symbol src="assets:symbols/amenity/fountain2.svg" /> + </m> + <m v="fuel"> + <symbol src="assets:symbols/transport/fuel.svg" /> + </m> + <m v="kindergarten"> + <symbol src="assets:symbols/education/nursery3.svg" /> + </m> + <m v="parking"> + <symbol src="assets:symbols/transport/parking.svg" /> + </m> + <m v="pharmacy"> + <symbol src="assets:symbols/health/pharmacy.svg" /> + </m> + <m v="place_of_worship"> + <m k="denomination|religion" v="buddhist"> + <symbol src="assets:symbols/place_of_worship/buddhist.svg" /> + </m> + <m k="denomination|religion" v="christian"> + <symbol src="assets:symbols/place_of_worship/christian.svg" /> + </m> + <m k="denomination|religion" v="hindu"> + <symbol src="assets:symbols/place_of_worship/hindu.svg" /> + </m> + <m k="denomination|religion" v="jewish"> + <symbol src="assets:symbols/place_of_worship/jewish.svg" /> + </m> + <m k="denomination|religion" v="muslim|moslem"> + <symbol src="assets:symbols/place_of_worship/islamic.svg" /> + </m> + <m k="denomination|religion" v="shinto"> + <symbol src="assets:symbols/place_of_worship/shinto.svg" /> + </m> + <m k="denomination|religion" v="~|*"> + <symbol src="assets:symbols/place_of_worship/unknown.svg" /> + </m> + </m> + <m v="post_box"> + <symbol src="assets:symbols/amenity/post_box.svg" /> + </m> + <m v="post_office"> + <symbol src="assets:symbols/amenity/post_office.svg" /> + </m> + <m v="recycling"> + <symbol src="assets:symbols/amenity/recycling.svg" /> + </m> + <m v="shelter"> + <symbol src="assets:symbols/accommodation/shelter2.svg" /> + </m> + <m v="telephone"> + <symbol src="assets:symbols/amenity/telephone.svg" /> + </m> + <m v="theatre"> + <symbol src="assets:symbols/tourist/theatre.svg" /> + </m> + <m select="when-matched"> + <text use="poi" /> + </m> + </m> + + <m zoom-min="17"> + <m v="toilets"> + <symbol src="assets:symbols/amenity/toilets.svg" /> + </m> + </m> + </m> + + <m k="shop"> + <m select="first" zoom-min="15"> + <m v="bakery"> + <symbol src="assets:symbols/shopping/bakery.svg" /> + </m> + <!--<m v="florist"> + <symbol src="assets:symbols/shopping/florist.svg" /> + </m>--> + <!--<m v="hairdresser" zoom-min="16"> + <symbol src="assets:symbols/shopping/hairdresser.svg" /> + </m>--> + <m v="supermarket|organic"> + <symbol src="assets:symbols/shopping/supermarket.svg" /> + </m> + + <m zoom-min="17"> + <symbol src="assets:symbols/dot_magenta.svg" /> + </m> + + <m select="when-matched" zoom-min="17"> + <text use="poi" /> + </m> + </m> + </m> + + <m k="tourism"> + <m select="first" zoom-min="15"> + <m v="alpine_hut"> + <symbol src="assets:symbols/accommodation/alpinehut.svg" /> + </m> + <m v="camp_site"> + <symbol src="assets:symbols/accommodation/camping.svg" /> + </m> + <m v="hostel"> + <symbol src="assets:symbols/accommodation/hostel.svg" /> + </m> + <m v="hotel"> + <symbol src="assets:symbols/accommodation/hotel2.svg" /> + </m> + + <m select="when-matched"> + <text use="poi" /> + </m> + </m> + + <!-- <m zoom-min="16" select="first"> + <m v="information" select="first"> + <m k="name"> + <symbol src="assets:symbols/tourist/information.svg" /> + <text use="poi" /> + </m> + <m> + <circle radius="1.5" fill="#ff0000" /> + </m> + </m> + </m> + --> + <m v="viewpoint"> + <symbol src="assets:symbols/tourist/view_point.svg" /> + </m> + <m v="museum"> + <symbol src="assets:symbols/tourist/museum.svg" /> + </m> + + </m> + + <m k="natural" v="peak" zoom-min="12"> + <symbol src="assets:symbols/peak.svg" /> + <caption style="bold" dy="12" fill="#4D2F08" k="ele" size="12" stroke="#ffffff" + stroke-width="2.0" /> + <caption style="bold" dy="-12" fill="#4D2F08" k="name" size="14" stroke="#ffffff" + stroke-width="2.0" /> + </m> + + <!-- house numbers --> + <m k="addr:housenumber" zoom-min="17"> + <caption style="bold" fill="#606060" k="addr:housenumber" size="12" stroke="#ffffff" + stroke-width="2.0" /> + </m> + </m> + +</rendertheme> diff --git a/vtm-themes/src/org/oscim/theme/VtmThemes.java b/vtm-themes/src/org/oscim/theme/VtmThemes.java index bb0146d2..41dc6403 100644 --- a/vtm-themes/src/org/oscim/theme/VtmThemes.java +++ b/vtm-themes/src/org/oscim/theme/VtmThemes.java @@ -32,6 +32,7 @@ public enum VtmThemes implements ThemeFile { DEFAULT("vtm/default.xml"), MAPZEN("vtm/mapzen.xml"), NEWTRON("vtm/newtron.xml"), + OPENMAPTILES("vtm/openmaptiles.xml"), OSMAGRAY("vtm/osmagray.xml"), OSMARENDER("vtm/osmarender.xml"), TRONRENDER("vtm/tronrender.xml");