From 34fefd28e1f50d8d0406e0aac4cb3909c94eb193 Mon Sep 17 00:00:00 2001 From: Daniel Cohen Gindi Date: Thu, 23 Jan 2020 10:18:28 +0200 Subject: maxHeight didn't account for the last label https://github.com/danielgindi/Charts/pull/3900 --- .../src/main/java/com/github/mikephil/charting/components/Legend.java | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'MPChartLib/src/main/java/com/github') diff --git a/MPChartLib/src/main/java/com/github/mikephil/charting/components/Legend.java b/MPChartLib/src/main/java/com/github/mikephil/charting/components/Legend.java index b7850988..70812925 100644 --- a/MPChartLib/src/main/java/com/github/mikephil/charting/components/Legend.java +++ b/MPChartLib/src/main/java/com/github/mikephil/charting/components/Legend.java @@ -703,8 +703,7 @@ public class Legend extends ComponentBase { width += Utils.calcTextWidth(labelpaint, label); - if (i < entryCount - 1) - maxHeight += labelLineHeight + yEntrySpace; + maxHeight += labelLineHeight + yEntrySpace; } else { wasStacked = true; width += formSize; -- cgit v1.2.3