mirror of
https://codeberg.org/Freeyourgadget/Gadgetbridge
synced 2024-11-27 20:36:51 +01:00
Pie Charts: some improvements wrt the labels
Still room for optimization. Thanks to Alberto!
This commit is contained in:
parent
8e780fa122
commit
f48729cc64
@ -139,6 +139,9 @@ public abstract class AbstractWeekChartFragment extends AbstractChartFragment {
|
||||
entries.add(new PieEntry(value, pieLabels[i]));
|
||||
}
|
||||
|
||||
set.setValueTextColor(DESCRIPTION_COLOR);
|
||||
set.setValueTextSize(13f);
|
||||
set.setXValuePosition(PieDataSet.ValuePosition.OUTSIDE_SLICE);
|
||||
set.setValueFormatter(getPieValueFormatter());
|
||||
set.setColors(getColors());
|
||||
|
||||
|
@ -105,6 +105,10 @@ public class SleepChartFragment extends AbstractChartFragment {
|
||||
}
|
||||
});
|
||||
set.setColors(colors);
|
||||
set.setValueTextColor(DESCRIPTION_COLOR);
|
||||
set.setValueTextSize(13f);
|
||||
set.setXValuePosition(PieDataSet.ValuePosition.OUTSIDE_SLICE);
|
||||
set.setYValuePosition(PieDataSet.ValuePosition.OUTSIDE_SLICE);
|
||||
data.setDataSet(set);
|
||||
|
||||
//setupLegend(pieChart);
|
||||
|
Loading…
Reference in New Issue
Block a user