diff options
author | Iván Ávalos <avalos@disroot.org> | 2022-01-13 03:09:40 -0600 |
---|---|---|
committer | Iván Ávalos <avalos@disroot.org> | 2022-01-13 03:09:40 -0600 |
commit | e4f46831685da5eeb927e2fa3c21dcd0374875c9 (patch) | |
tree | 604954f84c06042d8da158512fbc9e5865546c27 | |
parent | 72d4b1005a885fee7b44bdfcdffa830b27c7d12b (diff) | |
download | etbsa-trackermap-mobile-e4f46831685da5eeb927e2fa3c21dcd0374875c9.tar.gz etbsa-trackermap-mobile-e4f46831685da5eeb927e2fa3c21dcd0374875c9.tar.bz2 etbsa-trackermap-mobile-e4f46831685da5eeb927e2fa3c21dcd0374875c9.zip |
Replaced screen labels background with outline
-rw-r--r-- | androidApp/src/main/java/mx/trackermap/TrackerMap/android/map/MapFragment.kt | 17 | ||||
-rw-r--r-- | androidApp/src/main/res/values/colors.xml | 5 |
2 files changed, 13 insertions, 9 deletions
diff --git a/androidApp/src/main/java/mx/trackermap/TrackerMap/android/map/MapFragment.kt b/androidApp/src/main/java/mx/trackermap/TrackerMap/android/map/MapFragment.kt index b8fbc57..ef1e27f 100644 --- a/androidApp/src/main/java/mx/trackermap/TrackerMap/android/map/MapFragment.kt +++ b/androidApp/src/main/java/mx/trackermap/TrackerMap/android/map/MapFragment.kt @@ -1,7 +1,6 @@ package mx.trackermap.TrackerMap.android.map import android.graphics.Bitmap -import android.graphics.Color import android.os.Bundle import android.util.Log import android.view.LayoutInflater @@ -131,17 +130,18 @@ class MapFragment : GlobeMapFragment() { }.toTypedArray() val fontSize = context?.resources?.getDimensionPixelSize(R.dimen.marker_label_text_size) - val reportColor = ContextCompat.getColor(context!!, R.color.colorReport) - val labelColor = ContextCompat.getColor(context!!, R.color.colorMarkerLabel) - val labelBgColor = ContextCompat.getColor(context!!, R.color.bgColorMarkerLabel) + val colorReport = ContextCompat.getColor(context!!, R.color.colorReport) + val colorLabel = ContextCompat.getColor(context!!, R.color.colorMarkerLabel) + val colorLabelOutline = ContextCompat.getColor(context!!, R.color.colorMarkerLabelOutline) val vectorInfo = VectorInfo() - vectorInfo.setColor(reportColor) + vectorInfo.setColor(colorReport) vectorInfo.setLineWidth(20.0f) val labelInfo = LabelInfo() - labelInfo.textColor = labelColor - labelInfo.backgroundColor = labelBgColor + labelInfo.textColor = colorLabel + labelInfo.outlineColor = colorLabelOutline + labelInfo.outlineSize = 3.0f fontSize?.let { labelInfo.fontSize = it.toFloat() } @@ -233,6 +233,7 @@ class MapFragment : GlobeMapFragment() { val fontSize = context?.resources?.getDimensionPixelSize(R.dimen.marker_label_text_size) val colorFill = ContextCompat.getColor(context!!, R.color.colorGeofence) val colorLabel = ContextCompat.getColor(context!!, R.color.colorGeofenceLabel) + val colorLabelOutline = ContextCompat.getColor(context!!, R.color.colorMarkerLabelOutline) val vectorInfo = VectorInfo() vectorInfo.setColor(colorFill) @@ -240,6 +241,8 @@ class MapFragment : GlobeMapFragment() { val labelInfo = LabelInfo() labelInfo.textColor = colorLabel + labelInfo.outlineColor = colorLabelOutline + labelInfo.outlineSize = 3.0f fontSize?.let { labelInfo.fontSize = it.toFloat() } diff --git a/androidApp/src/main/res/values/colors.xml b/androidApp/src/main/res/values/colors.xml index b241148..bb4ab14 100644 --- a/androidApp/src/main/res/values/colors.xml +++ b/androidApp/src/main/res/values/colors.xml @@ -6,10 +6,11 @@ <color name="background">#FDFDFD</color> <color name="darkBackground">#ECEFF3</color> - <color name="colorMarkerLabel">#656A74</color> - <color name="bgColorMarkerLabel">#FFFFFF</color> + <color name="colorMarkerLabel">#43474E</color> + <color name="colorMarkerLabelOutline">#FFFFFF</color> <color name="colorGeofence">#1976D2</color> <color name="colorGeofenceLabel">#1976D2</color> + <color name="colorGeofenceLabelOutline">#FFFFFF</color> <color name="colorReport">#388E3C</color> <color name="colorOnline">#388E3C</color> |