From dceab2c2e878e9691d5e3e3fbb45d8609323b649 Mon Sep 17 00:00:00 2001 From: Andreas Schildbach Date: Fri, 5 Feb 2021 15:40:18 +0100 Subject: [PATCH] TripsGallery: Make current time label darker and use inverse text even in light mode. --- oeffi/res/values-night/colors.xml | 1 + oeffi/res/values/colors.xml | 3 ++- oeffi/src/de/schildbach/oeffi/directions/TripsGallery.java | 3 ++- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/oeffi/res/values-night/colors.xml b/oeffi/res/values-night/colors.xml index bf52647..a0653fd 100644 --- a/oeffi/res/values-night/colors.xml +++ b/oeffi/res/values-night/colors.xml @@ -3,6 +3,7 @@ #ffffff + #000000 #aaaaaa #888888 #ff9966 diff --git a/oeffi/res/values/colors.xml b/oeffi/res/values/colors.xml index af73168..4b4ccd2 100644 --- a/oeffi/res/values/colors.xml +++ b/oeffi/res/values/colors.xml @@ -3,6 +3,7 @@ #000000 + #ffffff #ffffff #999999 #aaaaaa @@ -26,7 +27,7 @@ #ffcfffaf #cccccc #cccccc - #eebb00 + #cc9900 #757575 #bbbbbb #ff4444 diff --git a/oeffi/src/de/schildbach/oeffi/directions/TripsGallery.java b/oeffi/src/de/schildbach/oeffi/directions/TripsGallery.java index 7264201..6b862bf 100644 --- a/oeffi/src/de/schildbach/oeffi/directions/TripsGallery.java +++ b/oeffi/src/de/schildbach/oeffi/directions/TripsGallery.java @@ -84,6 +84,7 @@ public class TripsGallery extends Gallery { density = res.getDisplayMetrics().density; final float strokeWidth = res.getDimension(R.dimen.trips_overview_stroke_width); final int colorSignificant = res.getColor(R.color.fg_significant); + final int colorSignificantInverse = res.getColor(R.color.fg_significant_inverse); final int colorCurrentTime = res.getColor(R.color.bg_current_time); gridPaint.setColor(Color.GRAY); @@ -107,7 +108,7 @@ public class TripsGallery extends Gallery { currenttimeLabelBackgroundPaint.setStrokeWidth(strokeWidth); currenttimeLabelBackgroundPaint.setAntiAlias(true); - currenttimeLabelTextPaint.setColor(Color.BLACK); + currenttimeLabelTextPaint.setColor(colorSignificantInverse); currenttimeLabelTextPaint.setAntiAlias(true); currenttimeLabelTextPaint.setTextSize(res.getDimension(R.dimen.font_size_normal)); currenttimeLabelTextPaint.setTypeface(Typeface.DEFAULT_BOLD);