[gnome-maps] geoJSONStyle: Change default line width and color to be more readable
- From: Marcus Lundblad <mlundblad src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-maps] geoJSONStyle: Change default line width and color to be more readable
- Date: Thu, 25 Jan 2018 20:37:02 +0000 (UTC)
commit 187528ff70d19af168e2fadf41a43237f5317b7a
Author: Marcus Lundblad <ml update uu se>
Date: Sun Oct 8 22:11:11 2017 +0200
geoJSONStyle: Change default line width and color to be more readable
Change the default line width to be in line with the lines used for
routing. Also use a more distinctive default color.
https://bugzilla.gnome.org/show_bug.cgi?id=788687
src/geoJSONStyle.js | 9 +++++----
1 files changed, 5 insertions(+), 4 deletions(-)
---
diff --git a/src/geoJSONStyle.js b/src/geoJSONStyle.js
index fce56bb..715baba 100644
--- a/src/geoJSONStyle.js
+++ b/src/geoJSONStyle.js
@@ -20,6 +20,9 @@
const Lang = imports.lang;
+const DEFAULT_LINE_WIDTH = 5;
+const DEFAULT_COLOR = 'AE274A';
+
var GeoJSONStyle = new Lang.Class({
Name: 'GeoJSONStyle',
@@ -28,7 +31,7 @@ var GeoJSONStyle = new Lang.Class({
if (params.lineWidth || params.lineWidth === 0)
this.lineWidth = params.lineWidth;
else
- this.lineWidth = 1;
+ this.lineWidth = DEFAULT_LINE_WIDTH;
if (params.alpha || params.alpha === 0)
this.alpha = params.alpha;
@@ -40,9 +43,7 @@ var GeoJSONStyle = new Lang.Class({
else
this.fillAlpha = 0.25;
- this.color = this._hexToColor(params.color) || { red: 0,
- green: 0,
- blue: 0 };
+ this.color = this._hexToColor(params.color || DEFAULT_COLOR);
this.fillColor = this._hexToColor(params.fillColor) || { red: 0.37,
green: 0.62,
blue: 0.87 };
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]