diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java index 62b2d7a028..60623d9665 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/OverviewFragment.java @@ -311,7 +311,7 @@ public class OverviewFragment extends Fragment implements View.OnClickListener, iobGraph.getGridLabelRenderer().setHorizontalLabelsVisible(false); bgGraph.getGridLabelRenderer().setLabelVerticalWidth(axisWidth); iobGraph.getGridLabelRenderer().setLabelVerticalWidth(axisWidth); - iobGraph.getGridLabelRenderer().setNumVerticalLabels(5); + iobGraph.getGridLabelRenderer().setNumVerticalLabels(3); rangeToDisplay = SP.getInt(R.string.key_rangetodisplay, 6); diff --git a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/graphData/GraphData.java b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/graphData/GraphData.java index d4a532979b..24ba8c1cea 100644 --- a/app/src/main/java/info/nightscout/androidaps/plugins/Overview/graphData/GraphData.java +++ b/app/src/main/java/info/nightscout/androidaps/plugins/Overview/graphData/GraphData.java @@ -604,8 +604,8 @@ public class GraphData { } } - graph.getViewport().setMaxY(maxY); - graph.getViewport().setMinY(minY); + graph.getViewport().setMaxY(Round.ceilTo(maxY, 1d)); + graph.getViewport().setMinY(Round.floorTo(minY, 1d)); graph.getViewport().setYAxisBoundsManual(true); // draw it