From 51f3078facf84d07d897553c9f2ebe7b6044e095 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Michael=20Stra=C3=9Fburger?= Date: Wed, 21 Sep 2016 06:19:36 +0200 Subject: [PATCH] :art: not rendering polygon roads, not filling building --- README.md | 2 ++ styles/bright.json | 4 ++-- termap.coffee | 6 +++++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 34b59c2..24b1271 100644 --- a/README.md +++ b/README.md @@ -45,6 +45,8 @@ No web browser around? No worries - discover the planet in your console! ### TODOs * [ ] cli linking * [ ] mapping of view to tiles to show +* [ ] line drawing + * [ ] support for stroke width * [ ] label drawing * [x] support for point labels * [x] dynamic decluttering of labels diff --git a/styles/bright.json b/styles/bright.json index 6dcc224..ff36ba3 100644 --- a/styles/bright.json +++ b/styles/bright.json @@ -214,11 +214,11 @@ "stops": [ [ 15.5, - "#f2eae2" + "#525652" ], [ 16, - "#dfdbd7" + "#5f5b57" ] ] } diff --git a/termap.coffee b/termap.coffee index 9bb40f0..64a62de 100644 --- a/termap.coffee +++ b/termap.coffee @@ -79,7 +79,7 @@ class Termap minZoom: 2 color: 8 building: - minZoom: 2.5 + minZoom: 3.8 color: 8 poi_label: @@ -265,6 +265,10 @@ class Termap drawn _drawFeature: (layer, feature, scale) -> + # TODO: this is ugly :) need to be fixed @style + return false if layer is 'road' and feature.type is "Polygon" + feature.type = "LineString" if layer is "building" + toDraw = [] for idx, points of feature.points visible = false