From 2d4645f6cc17e908103d4e91ce6c515382fb6e26 Mon Sep 17 00:00:00 2001 From: cpfeiffer Date: Thu, 24 Nov 2016 23:34:33 +0100 Subject: [PATCH] Fix only the first day label being displayed in Week Steps charts --- .../activities/charts/AbstractChartFragment.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/charts/AbstractChartFragment.java b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/charts/AbstractChartFragment.java index 3363e79d..b1beeb77 100644 --- a/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/charts/AbstractChartFragment.java +++ b/app/src/main/java/nodomain/freeyourgadget/gadgetbridge/activities/charts/AbstractChartFragment.java @@ -346,7 +346,10 @@ public abstract class AbstractChartFragment extends AbstractGBFragment { // enable touch gestures chart.setTouchEnabled(true); - chart.getXAxis().setGranularity(60*5); +// commented out: this has weird bugs/sideeffects at least on WeekStepsCharts +// where only the first Day-label is drawn, because AxisRenderer.computeAxisValues(float,float) +// appears to have an overflow when calculating 'n' (number of entries) +// chart.getXAxis().setGranularity(60*5); setupLegend(chart); }